Chromium Code Reviews| Index: tools/run-tests.py |
| diff --git a/tools/run-tests.py b/tools/run-tests.py |
| index 03ad716c67328ddfb4656188cbeba1a68330987d..eea90679a1fe581a45d1e09ca6a6ed2f5c3fb116 100755 |
| --- a/tools/run-tests.py |
| +++ b/tools/run-tests.py |
| @@ -171,6 +171,9 @@ def BuildOptions(): |
| help="Comma-separated list of testing variants") |
| result.add_option("--outdir", help="Base directory with compile output", |
| default="out") |
| + result.add_option("--predictable", |
| + help="Compare output of several reruns of each test", |
| + default=False, action="store_true") |
| result.add_option("-p", "--progress", |
| help=("The style of progress indicator" |
| " (verbose, dots, color, mono)"), |
| @@ -301,6 +304,10 @@ def ProcessOptions(options): |
| options.flaky_tests = "skip" |
| options.slow_tests = "skip" |
| options.pass_fail_tests = "skip" |
| + if options.predictable: |
| + VARIANTS = ["default"] |
| + options.extra_flags.append("--predictable") |
| + options.extra_flags.append("--verify_predictable") |
|
Igor Sheludko
2014/07/08 13:15:20
Add --no-inline-new to make the synthetic "time" i
|
| if not options.shell_dir: |
| if options.shell: |
| @@ -416,6 +423,11 @@ def Execute(arch, mode, args, options, suites, workspace): |
| timeout = TIMEOUT_DEFAULT; |
| timeout *= TIMEOUT_SCALEFACTOR[mode] |
| + |
| + if options.predictable: |
| + # Predictable mode is slower. |
| + timeout *= 2 |
| + |
| ctx = context.Context(arch, mode, shell_dir, |
| mode_flags, options.verbose, |
| timeout, options.isolates, |
| @@ -425,7 +437,8 @@ def Execute(arch, mode, args, options, suites, workspace): |
| options.random_seed, |
| options.no_sorting, |
| options.rerun_failures_count, |
| - options.rerun_failures_max) |
| + options.rerun_failures_max, |
| + options.predictable) |
| # TODO(all): Combine "simulator" and "simulator_run". |
| simulator_run = not options.dont_skip_simulator_slow_tests and \ |