diff options
| author | Jenkins <jenkins@review.openstack.org> | 2016-04-25 21:15:43 +0000 |
|---|---|---|
| committer | Gerrit Code Review <review@openstack.org> | 2016-04-25 21:15:43 +0000 |
| commit | 74162fa31a3c34ee08472f24318f1c326b493330 (patch) | |
| tree | 2630dafbee9dd36ef2681b05abd7f270c8c00bfd /openstackclient/tests | |
| parent | a0a29df3e67b29880e62e1974dde18a4993f2aa1 (diff) | |
| parent | 27024d70af4756cb6e4b210b025ed7427541f773 (diff) | |
| download | python-openstackclient-74162fa31a3c34ee08472f24318f1c326b493330.tar.gz | |
Merge "Support quota show for current project"
Diffstat (limited to 'openstackclient/tests')
| -rw-r--r-- | openstackclient/tests/common/test_quota.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/openstackclient/tests/common/test_quota.py b/openstackclient/tests/common/test_quota.py index edf29c9b..ba7ee469 100644 --- a/openstackclient/tests/common/test_quota.py +++ b/openstackclient/tests/common/test_quota.py @@ -59,6 +59,7 @@ class TestQuota(compute_fakes.TestComputev2): self.service_catalog_mock = \ self.app.client_manager.auth_ref.service_catalog self.service_catalog_mock.reset_mock() + self.app.client_manager.auth_ref.project_id = identity_fakes.project_id class TestQuotaSet(TestQuota): @@ -304,3 +305,13 @@ class TestQuotaShow(TestQuota): identity_fakes.project_id) self.volume_quotas_class_mock.get.assert_called_with( identity_fakes.project_id) + + def test_quota_show_no_project(self): + parsed_args = self.check_parser(self.cmd, [], []) + + self.cmd.take_action(parsed_args) + + self.quotas_mock.get.assert_called_with(identity_fakes.project_id) + self.volume_quotas_mock.get.assert_called_with( + identity_fakes.project_id) + self.network.get_quota.assert_called_with(identity_fakes.project_id) |
