From ebe708924c3559fb60be353ec8a4c56609320ad4 Mon Sep 17 00:00:00 2001 From: Ken'ichi Ohmichi Date: Thu, 9 Feb 2017 10:06:30 -0800 Subject: [PATCH] Switch to use test_utils.call_until_true test.call_until_true has been deprecated since Newton on Tempest side, and now Tempest provides test_utils.call_until_true as the stable library method. So this patch switches to use the stable method before removing old test.call_until_true on Tempest side. Change-Id: Ia4b8cf5ac58daaadac0a1ec4a55e50f312ecd256 (cherry picked from commit d77b2635e6282398029194b1ba6daf3b94b3f188) --- ironic_tempest_plugin/tests/scenario/baremetal_manager.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ironic_tempest_plugin/tests/scenario/baremetal_manager.py b/ironic_tempest_plugin/tests/scenario/baremetal_manager.py index 286750ded1..a5d5f208e9 100644 --- a/ironic_tempest_plugin/tests/scenario/baremetal_manager.py +++ b/ironic_tempest_plugin/tests/scenario/baremetal_manager.py @@ -16,9 +16,9 @@ from tempest.common import waiters from tempest import config +from tempest.lib.common.utils import test_utils from tempest.lib import exceptions as lib_exc from tempest.scenario import manager # noqa -import tempest.test from ironic_tempest_plugin import clients @@ -84,7 +84,7 @@ class BaremetalScenarioTest(manager.ScenarioTest): return True return False - if not tempest.test.call_until_true(check_state, timeout, interval): + if not test_utils.call_until_true(check_state, timeout, interval): msg = ("Timed out waiting for node %s to reach %s state(s) %s" % (node_id, state_attr, target_states)) raise lib_exc.TimeoutException(msg) @@ -110,7 +110,7 @@ class BaremetalScenarioTest(manager.ScenarioTest): pass return node is not None - if (not tempest.test.call_until_true( + if (not test_utils.call_until_true( _get_node, CONF.baremetal.association_timeout, 1)): msg = ('Timed out waiting to get Ironic node by instance id %s' % instance_id)