From 6b271bdbd529ffb62eeb8cd14a3abe72aeeb3353 Mon Sep 17 00:00:00 2001 From: JingLu5 Date: Fri, 23 Feb 2018 08:04:06 +0000 Subject: [bugfix]tc006 failed due to volume attached to different location "/dev/vdc" JIRA: YARDSTICK-857 The yardstick test suites are failing for os-odl-bgpvpn-ha and os-odl-bgpvpn-noha scenarios installed with apex. Here are the yardstick test run logs: os-odl-bgpvpn-ha: https://build.opnfv.org/ci/job/yardstick-apex-baremetal-daily-master/624//consoleFull, https://build.opnfv.org/ci/job/yardstick-apex-baremetal-daily-master/640//consoleFull os-odl-bgpvpn-noha: https://build.opnfv.org/ci/job/yardstick-apex-baremetal-daily-master/637//console The root cause of the problem is in some environment the block device cannot be attached to the target path. In this patch, the actually device path is found and used. Change-Id: I46c601960a0668c81f9b73504ef9553f9e8591dc Signed-off-by: JingLu5 --- .../tests/unit/benchmark/scenarios/storage/test_fio.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'yardstick/tests/unit/benchmark/scenarios/storage') diff --git a/yardstick/tests/unit/benchmark/scenarios/storage/test_fio.py b/yardstick/tests/unit/benchmark/scenarios/storage/test_fio.py index 0cffea224..a713ce728 100644 --- a/yardstick/tests/unit/benchmark/scenarios/storage/test_fio.py +++ b/yardstick/tests/unit/benchmark/scenarios/storage/test_fio.py @@ -63,6 +63,22 @@ class FioTestCase(unittest.TestCase): } args = {'options': options} p = fio.Fio(args, self.ctx) + mock_ssh.SSH.from_node().execute.return_value = (0, '/dev/vdb', '') + p.setup() + + mock_ssh.SSH.from_node().execute.return_value = (0, '', '') + self.assertIsNotNone(p.client) + self.assertTrue(p.setup_done) + + def test_fio_job_file_no_disk__setup(self, mock_ssh): + + options = { + 'job_file': 'job_file.ini', + 'directory': '/FIO_Test' + } + args = {'options': options} + p = fio.Fio(args, self.ctx) + mock_ssh.SSH.from_node().execute.return_value = (0, '', '') p.setup() mock_ssh.SSH.from_node().execute.return_value = (0, '', '') -- cgit 1.2.3-korg