From 5521e4c504c6a3a06f17a9e4f80444743aa293c7 Mon Sep 17 00:00:00 2001 From: Roxana Gherle Date: Fri, 22 May 2015 16:22:35 -0700 Subject: Add --os-endpoint-type cli optional argument User should be able to specify the endpoint type through a CLI optional argument/ENV variable setting. We will name this new optional argument: --os-endpoint-type (Env: OS_ENDPOINT_TYPE) and based on the value given, the service API will use that specific endpoint type. Possible values: public, admin, internal. DocImpact Closes-Bug: #1454392 Change-Id: Ife3d4e46b44c0ddcd712b1130e27e362545a9a29 --- openstackclient/tests/common/test_utils.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'openstackclient/tests/common/test_utils.py') diff --git a/openstackclient/tests/common/test_utils.py b/openstackclient/tests/common/test_utils.py index d9f5b7a5..a25a5ba5 100644 --- a/openstackclient/tests/common/test_utils.py +++ b/openstackclient/tests/common/test_utils.py @@ -159,6 +159,16 @@ class TestUtils(test_utils.TestCase): self.assertFalse(utils.wait_for_delete(manager, res_id)) self.assertFalse(mock_sleep.called) + def test_build_kwargs_dict_value_set(self): + self.assertEqual({'arg_bla': 'bla'}, + utils.build_kwargs_dict('arg_bla', 'bla')) + + def test_build_kwargs_dict_value_None(self): + self.assertEqual({}, utils.build_kwargs_dict('arg_bla', None)) + + def test_build_kwargs_dict_value_empty_str(self): + self.assertEqual({}, utils.build_kwargs_dict('arg_bla', '')) + class NoUniqueMatch(Exception): pass -- cgit v1.2.1