Bug 1547983 - [mochitest] Fix running a single mochitest-plain-clipboard/gpu test locally, r=jmaher

This was a regression from bug 1546100.

Differential Revision: https://phabricator.services.mozilla.com/D29390

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Andrew Halberstadt 2019-04-30 21:09:16 +00:00
parent b129dd3e10
commit e108b019b8
2 changed files with 4 additions and 3 deletions

View File

@ -140,7 +140,8 @@ class MochitestRunner(MozbuildObject):
# refresh the page to pick up modifications. Therefore leave the browser
# open if only running a single mochitest-plain test. This behaviour can
# be overridden by passing in --keep-open=false.
if len(tests) == 1 and options.keep_open is None and options.flavor == 'plain':
flavor = getattr(options, 'flavor', 'plain')
if len(tests) == 1 and options.keep_open is None and flavor == 'plain':
options.keep_open = True
# We need this to enable colorization of output.

View File

@ -145,14 +145,14 @@ TEST_SUITES = {
'mochitest-plain-clipboard': {
'aliases': ('cl', 'clipboard',),
'mach_command': 'mochitest',
'kwargs': {'subsuite': 'clipboard', 'test_paths': None},
'kwargs': {'flavor': 'plain', 'subsuite': 'clipboard', 'test_paths': None},
'task_regex': ['mochitest-clipboard($|.*(-1|[^0-9])$)',
'test-verify($|.*(-1|[^0-9])$)'],
},
'mochitest-plain-gpu': {
'aliases': ('gpu',),
'mach_command': 'mochitest',
'kwargs': {'subsuite': 'gpu', 'test_paths': None},
'kwargs': {'flavor': 'plain', 'subsuite': 'gpu', 'test_paths': None},
'task_regex': ['mochitest-gpu($|.*(-1|[^0-9])$)',
'test-verify($|.*(-1|[^0-9])$)'],
},