mirror of
https://github.com/servo/servo.git
synced 2025-08-04 05:00:08 +01:00
Implement --pref in test-wpt
This commit is contained in:
parent
3a28aad349
commit
429c82bdf1
1 changed files with 8 additions and 0 deletions
|
@ -42,6 +42,8 @@ def create_parser_wpt():
|
||||||
help="Run with a release build of servo")
|
help="Run with a release build of servo")
|
||||||
parser.add_argument('--chaos', default=False, action="store_true",
|
parser.add_argument('--chaos', default=False, action="store_true",
|
||||||
help="Run under chaos mode in rr until a failure is captured")
|
help="Run under chaos mode in rr until a failure is captured")
|
||||||
|
parser.add_argument('--pref', default=[], action="append", dest="prefs",
|
||||||
|
help="Pass preferences to servo")
|
||||||
return parser
|
return parser
|
||||||
|
|
||||||
|
|
||||||
|
@ -321,6 +323,12 @@ class MachCommands(CommandBase):
|
||||||
kwargs["debugger_args"] = "record --chaos"
|
kwargs["debugger_args"] = "record --chaos"
|
||||||
kwargs["repeat_until_unexpected"] = True
|
kwargs["repeat_until_unexpected"] = True
|
||||||
# TODO: Delete rr traces from green test runs?
|
# TODO: Delete rr traces from green test runs?
|
||||||
|
prefs = kwargs.pop("prefs")
|
||||||
|
if prefs:
|
||||||
|
binary_args = []
|
||||||
|
for pref in prefs:
|
||||||
|
binary_args.append("--pref=" + pref)
|
||||||
|
kwargs["binary_args"] = binary_args
|
||||||
|
|
||||||
run_globals = {"__file__": run_file}
|
run_globals = {"__file__": run_file}
|
||||||
execfile(run_file, run_globals)
|
execfile(run_file, run_globals)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue