diff --git a/tripleoclient/tests/test_utils.py b/tripleoclient/tests/test_utils.py index 6a5a96fcd..5ae0aa6cc 100644 --- a/tripleoclient/tests/test_utils.py +++ b/tripleoclient/tests/test_utils.py @@ -530,7 +530,7 @@ class TestWaitForStackUtil(TestCase): mock_get_stack.return_value = stack mock_poll.side_effect = hc_exc.HTTPException(code=500) - self.assertRaises(hc_exc.HTTPException, + self.assertRaises(RuntimeError, utils.wait_for_stack_ready, self.mock_orchestration, 'stack') diff --git a/tripleoclient/utils.py b/tripleoclient/utils.py index ad48b4bc2..c414127d1 100644 --- a/tripleoclient/utils.py +++ b/tripleoclient/utils.py @@ -521,7 +521,7 @@ def wait_for_stack_ready(orchestration_client, stack_name, marker=None, print(msg) return stack_status == '%s_COMPLETE' % action except hc_exc.HTTPException as e: - if e.code in [503, 504]: + if e.code in [500, 503, 504]: retries += 1 log.warning("Server issue while waiting for stack to be ready." " Attempting retry {} of {}".format(retries,