diff options
author | rabi <ramishra@redhat.com> | 2018-04-24 16:41:19 +0530 |
---|---|---|
committer | rabi <ramishra@redhat.com> | 2018-04-24 16:47:11 +0530 |
commit | 685f95b49de6800d8ed6eebeb32ea3a1dc64fc26 (patch) | |
tree | 9f93989ae7618e96778857a901ae9154aad1695d /heat_integrationtests | |
parent | 5b785eb22706e48fd210860131dccc86c7c3a31e (diff) | |
download | heat-685f95b49de6800d8ed6eebeb32ea3a1dc64fc26.tar.gz |
Do deepcopy when copying templates
test_template is defined as a dict, so do a deepcopy
instead.
Change-Id: I0f7d222d5f95aa8e8ed73ae0d7a100470271e113
Closes-Bug: #1766448
Diffstat (limited to 'heat_integrationtests')
-rw-r--r-- | heat_integrationtests/functional/test_update_restricted.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/heat_integrationtests/functional/test_update_restricted.py b/heat_integrationtests/functional/test_update_restricted.py index 23a0a5828..0c5d015f0 100644 --- a/heat_integrationtests/functional/test_update_restricted.py +++ b/heat_integrationtests/functional/test_update_restricted.py @@ -10,6 +10,7 @@ # License for the specific language governing permissions and limitations # under the License. +import copy import time from heat_integrationtests.functional import functional_base @@ -57,7 +58,7 @@ class UpdateRestrictedStackTest(functional_base.FunctionalTestsBase): def test_update(self): stack_identifier = self.stack_create(template=test_template) - update_template = test_template.copy() + update_template = copy.deepcopy(test_template) props = update_template['resources']['bar']['properties'] props['value'] = '4567' @@ -94,7 +95,7 @@ class UpdateRestrictedStackTest(functional_base.FunctionalTestsBase): def test_replace(self): stack_identifier = self.stack_create(template=test_template) - update_template = test_template.copy() + update_template = copy.deepcopy(test_template) props = update_template['resources']['bar']['properties'] props['value'] = '4567' props['update_replace'] = True @@ -132,7 +133,7 @@ class UpdateRestrictedStackTest(functional_base.FunctionalTestsBase): def test_update_type_changed(self): stack_identifier = self.stack_create(template=test_template) - update_template = test_template.copy() + update_template = copy.deepcopy(test_template) rsrc = update_template['resources']['bar'] rsrc['type'] = 'OS::Heat::None' |