v3 test utils, don't modify input parameter

As mentioned in https://review.openstack.org/#/c/61046/ for
test_update, we should not modify the input req_ref in test_create
instead we should make a copy

Change-Id: I649433596a3ebbf2133eb724f09eb4bd470b7cdd
This commit is contained in:
Steven Hardy
2013-12-20 16:33:51 +00:00
parent 045e03d852
commit dfda9a84f2

View File

@@ -193,7 +193,7 @@ class CrudTests(object):
# signature for the request when the manager does some
# conversion before doing the request (e.g converting
# from datetime object to timestamp string)
req_ref = req_ref or ref.copy()
req_ref = (req_ref or ref).copy()
req_ref.pop('id')
self.stub_entity(httpretty.POST, entity=req_ref, status=201)