summaryrefslogtreecommitdiffstats
path: root/tests/unit/benchmark/scenarios/networking/test_iperf3.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/benchmark/scenarios/networking/test_iperf3.py')
-rw-r--r--tests/unit/benchmark/scenarios/networking/test_iperf3.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/unit/benchmark/scenarios/networking/test_iperf3.py b/tests/unit/benchmark/scenarios/networking/test_iperf3.py
index 45ff1b779..331245357 100644
--- a/tests/unit/benchmark/scenarios/networking/test_iperf3.py
+++ b/tests/unit/benchmark/scenarios/networking/test_iperf3.py
@@ -19,6 +19,7 @@ import unittest
import mock
from oslo_serialization import jsonutils
+from yardstick.common import utils
from yardstick.benchmark.scenarios.networking import iperf3
@@ -81,7 +82,7 @@ class IperfTestCase(unittest.TestCase):
sample_output = self._read_sample_output(self.output_name_tcp)
mock_ssh.SSH.from_node().execute.return_value = (0, sample_output, '')
- expected_result = jsonutils.loads(sample_output)
+ expected_result = utils.flatten_dict_key(jsonutils.loads(sample_output))
p.run(result)
self.assertEqual(result, expected_result)
@@ -100,7 +101,7 @@ class IperfTestCase(unittest.TestCase):
sample_output = self._read_sample_output(self.output_name_tcp)
mock_ssh.SSH.from_node().execute.return_value = (0, sample_output, '')
- expected_result = jsonutils.loads(sample_output)
+ expected_result = utils.flatten_dict_key(jsonutils.loads(sample_output))
p.run(result)
self.assertEqual(result, expected_result)
@@ -135,7 +136,7 @@ class IperfTestCase(unittest.TestCase):
sample_output = self._read_sample_output(self.output_name_udp)
mock_ssh.SSH.from_node().execute.return_value = (0, sample_output, '')
- expected_result = jsonutils.loads(sample_output)
+ expected_result = utils.flatten_dict_key(jsonutils.loads(sample_output))
p.run(result)
self.assertEqual(result, expected_result)