提交 6a17f48b 编写于 作者: C Cleber Rosa

job main loop: another round of functional test timeout adjustment

Looks like a travis worker can be a lot slower than I thought at first,
in the order of 50 times slower than a 2 year old development machine.

So now, the timeout is 250 times higher than the test run would take
under the mentioned development machine (0.12s), but still able to
catch bugs if the loop does not cycle immediatelly on failure for the
100 failtests.
Signed-off-by: NCleber Rosa <crosa@redhat.com>
上级 6d55fda4
......@@ -208,10 +208,10 @@ class RunnerDropinTest(unittest.TestCase):
def test_runner_onehundred_fail_timing(self):
"""
We can be pretty sure that a failtest should return immediattely. Let's
run 100 of them and assure they not take more than 3 seconds to run.
run 100 of them and assure they not take more than 30 seconds to run.
Notice: on a current machine this takes about 0.12s, so 3 second is
pretty safe here.
Notice: on a current machine this takes about 0.12s, so 30 seconds is
considered to be pretty safe here.
"""
os.chdir(basedir)
one_hundred = 'failtest ' * 100
......@@ -219,7 +219,7 @@ class RunnerDropinTest(unittest.TestCase):
initial_time = time.time()
result = process.run(cmd_line, ignore_status=True)
actual_time = time.time() - initial_time
self.assertLess(actual_time, 3.0)
self.assertLess(actual_time, 30.0)
expected_rc = 1
self.assertEqual(result.exit_status, expected_rc,
"Avocado did not return rc %d:\n%s" % (expected_rc, result))
......@@ -235,7 +235,7 @@ class RunnerDropinTest(unittest.TestCase):
initial_time = time.time()
result = process.run(cmd_line, ignore_status=True)
actual_time = time.time() - initial_time
self.assertLess(actual_time, 6.0)
self.assertLess(actual_time, 33.0)
expected_rc = 1
self.assertEqual(result.exit_status, expected_rc,
"Avocado did not return rc %d:\n%s" % (expected_rc, result))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册