def wait_until_evaluation_status_code_is(step, code1, code2, secs):
    start = datetime.utcnow()
    i_get_the_evaluation(step, world.evaluation['resource'])
    status = get_status(world.evaluation)
    while (status['code'] != int(code1) and
           status['code'] != int(code2)):
        time.sleep(3)
        assert start - datetime.utcnow() < timedelta(seconds=int(secs))
        i_get_the_evaluation(step, world.evaluation['resource'])
        status = get_status(world.evaluation)
    assert status['code'] == int(code1)

#@step(r'I wait until the evaluation is ready less than (\d+)')
dataset/ETHPy150Open bigmlcom/python/bigml/tests/create_evaluation_steps.py/wait_until_evaluation_status_code_is/swapped operands of `-`