diff options
author | Ricardo Martincoski <ricardo.martincoski@gmail.com> | 2017-08-04 23:05:19 -0300 |
---|---|---|
committer | Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> | 2017-08-10 10:08:06 +0200 |
commit | 6e45e33f27d5ae6fa0ab5aad3f032d886a886037 (patch) | |
tree | 14dc7955a31e639ceabd20c59399765162842355 /support/testing/run-tests | |
parent | 128a16aceeb43d7d22b10c6845f7c4d09439e031 (diff) | |
download | buildroot-6e45e33f27d5ae6fa0ab5aad3f032d886a886037.tar.gz buildroot-6e45e33f27d5ae6fa0ab5aad3f032d886a886037.zip |
support/testing: allow to use a multiplier for timeouts
Add a parameter to run-tests to act as a multiplier for all timeouts of
emulator.
It can be used to avoid sporadic failures on slow host machines as well
in elastic runners on the cloud.
Cc: Arnout Vandecappelle <arnout@mind.be>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com>
[Arnout: rename multiplier to timeout_multiplier everywhere]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Diffstat (limited to 'support/testing/run-tests')
-rwxr-xr-x | support/testing/run-tests | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/support/testing/run-tests b/support/testing/run-tests index 0cb673c61f..95c1565f72 100755 --- a/support/testing/run-tests +++ b/support/testing/run-tests @@ -28,6 +28,8 @@ def main(): help='number of testcases to run simultaneously') parser.add_argument('-j', '--jlevel', type=int, help='BR2_JLEVEL to use for each testcase') + parser.add_argument('--timeout-multiplier', type=int, default=1, + help='increase timeouts (useful for slow machines)') args = parser.parse_args() @@ -97,6 +99,13 @@ def main(): # the user can override the auto calculated value BRTest.jlevel = args.jlevel + if args.timeout_multiplier < 1: + print "Invalid multiplier for timeout values" + print "" + parser.print_help() + return 1 + BRTest.timeout_multiplier = args.timeout_multiplier + nose2_args = ["-v", "-N", str(args.testcases), "-s", "support/testing", |