resource: fix help string

Change-Id: If0d20ec7777550432a417ab73f479d02d12d94c1
Closes-Bug: #1505788
This commit is contained in:
Julien Danjou 2015-10-14 16:44:01 +02:00
parent 63e56b6990
commit 13c694a6df
2 changed files with 11 additions and 6 deletions

View File

@ -20,6 +20,11 @@ class ResourceClientTest(base.ClientTestBase):
RESOURCE_ID2 = str(uuid.uuid4())
PROJECT_ID = str(uuid.uuid4())
def test_help(self):
self.gnocchi("help", params="resource list")
self.gnocchi("help", params="resource history")
self.gnocchi("help", params="resource search")
def test_resource_scenario(self):
# CREATE
result = self.gnocchi(

View File

@ -34,14 +34,14 @@ class CliResourceList(lister.Lister):
parser.add_argument("--history", action='store_true',
help="Show history of the resources"),
parser.add_argument("--limit", type=int, metavar="<LIMIT>",
help=("Number of resources to return "
"(Default is server default)"))
help="Number of resources to return "
"(Default is server default)")
parser.add_argument("--marker", metavar="<MARKER>",
help=("Last item of the previous listing. "
"Return the next results after this value"))
help="Last item of the previous listing. "
"Return the next results after this value")
parser.add_argument("--sort", action="append", metavar="<SORT>",
help=("Sort of resource attribute ",
"(example: user_id:desc-nullslast"))
help="Sort of resource attribute "
"(example: user_id:desc-nullslast")
parser.add_argument("--type", "-t", dest="resource_type",
default="generic", help="Type of resource")
return parser