summaryrefslogtreecommitdiff
path: root/openstackclient/tests
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2016-03-11 20:48:32 +0000
committerGerrit Code Review <review@openstack.org>2016-03-11 20:48:32 +0000
commit586a038afd26894b264bd716186ff1b9ad8844f9 (patch)
tree16d2a3d18e4f3e3e089fd86d245270f8cd272843 /openstackclient/tests
parent3737c5a842f727ad9d28fd10af67784efc6ab416 (diff)
parentf0c3b4e69dc56934305442b505d5f5f68579f1f2 (diff)
downloadpython-openstackclient-586a038afd26894b264bd716186ff1b9ad8844f9.tar.gz
Merge "Fixed command list"
Diffstat (limited to 'openstackclient/tests')
-rw-r--r--openstackclient/tests/common/test_module.py16
1 files changed, 10 insertions, 6 deletions
diff --git a/openstackclient/tests/common/test_module.py b/openstackclient/tests/common/test_module.py
index 2821da9e..7d08dae7 100644
--- a/openstackclient/tests/common/test_module.py
+++ b/openstackclient/tests/common/test_module.py
@@ -48,10 +48,11 @@ class TestCommandList(utils.TestCommand):
super(TestCommandList, self).setUp()
self.app.command_manager = mock.Mock()
- self.app.command_manager.get_command_groups.return_value = ['test']
+ self.app.command_manager.get_command_groups.return_value = [
+ 'openstack.common'
+ ]
self.app.command_manager.get_command_names.return_value = [
- 'one',
- 'cmd two',
+ 'limits show\nextension list'
]
# Get the command object to test
@@ -67,12 +68,15 @@ class TestCommandList(utils.TestCommand):
# containing the data to be listed.
columns, data = self.cmd.take_action(parsed_args)
+ # TODO(bapalm): Adjust this when cliff properly supports
+ # handling the detection rather than using the hard-code below.
collist = ('Command Group', 'Commands')
self.assertEqual(collist, columns)
datalist = ((
- 'test',
- ['one', 'cmd two'],
- ), )
+ 'openstack.common',
+ 'limits show\nextension list'
+ ),)
+
self.assertEqual(datalist, tuple(data))