Fix a bug for node context 99/17299/1
authorSongnon <songnon.zhang@ericsson.com>
Wed, 20 Jul 2016 08:13:59 +0000 (16:13 +0800)
committerSongnon <songnon.zhang@ericsson.com>
Thu, 21 Jul 2016 05:46:46 +0000 (13:46 +0800)
Change-Id: Idff42e95f5ade160c00adc13c158dc1746e8d049
Signed-off-by: Songnon <songnon.zhang@ericsson.com>
yardstick/benchmark/contexts/node.py

index 54ee076..c3d6521 100644 (file)
@@ -82,6 +82,8 @@ class NodeContext(Context):
             LOG.error("Nodes: %r" % nodes)
             sys.exit(-1)
 
-        node = nodes[0]
+        # A clone is created in order to avoid affecting the
+        # original one.
+        node = dict(nodes[0])
         node["name"] = attr_name
         return node