summaryrefslogtreecommitdiffstats
path: root/functest/tests
diff options
context:
space:
mode:
authorCédric Ollivier <cedric.ollivier@orange.com>2017-02-14 11:16:22 +0100
committerCédric Ollivier <cedric.ollivier@orange.com>2017-02-14 11:24:07 +0100
commit4c142226db85c89c5459737715223b7be30bd17e (patch)
tree2647e89f0ddeb629fe6548ab56f0c4c88697a39b /functest/tests
parent66d02a85d91c5981ae3c2ebf5fa5b1e51c7ad143 (diff)
Limit the substitution of ' in env vars
Only ' located and the beginning or at the end of the string are removed. It completes the first proposal [1]. [1] https://gerrit.opnfv.org/gerrit/#/c/28563/ Change-Id: Ic21cea4c6e98d92983f385c875c3e214411b5f2d Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
Diffstat (limited to 'functest/tests')
-rw-r--r--functest/tests/unit/utils/test_openstack_utils.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/functest/tests/unit/utils/test_openstack_utils.py b/functest/tests/unit/utils/test_openstack_utils.py
index 0971b4e8..447271fc 100644
--- a/functest/tests/unit/utils/test_openstack_utils.py
+++ b/functest/tests/unit/utils/test_openstack_utils.py
@@ -379,6 +379,9 @@ class OSUtilsTesting(unittest.TestCase):
self._test_source_credentials('export OS_TENANT_NAME = "admin"')
self._test_source_credentials('OS_TENANT_NAME', value='')
self._test_source_credentials('export OS_TENANT_NAME', value='')
+ # This test will fail as soon as rc_file is fixed
+ self._test_source_credentials(
+ 'export "\'OS_TENANT_NAME\'" = "\'admin\'"')
@mock.patch('functest.utils.openstack_utils.os.getenv',
return_value=None)