Bug 938712 - Dispatch mach test mochitest suites via mach mochitest; r=AutomatedTester
authorGregory Szorc <gps@mozilla.com>
Tue, 17 Jun 2014 16:03:49 -0700
changeset 210576 5301f1aaf305e690126509657eff749db5d805b1
parent 210575 3dedef93c16dc1ad9ac7716a89dec9e9daf12b1a
child 210577 78bf44ce0d1b2ed0959068df185b16b1016f2d58
push id3857
push userraliiev@mozilla.com
push dateTue, 02 Sep 2014 16:39:23 +0000
treeherdermozilla-beta@5638b907b505 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersAutomatedTester
bugs938712
milestone33.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 938712 - Dispatch mach test mochitest suites via mach mochitest; r=AutomatedTester `mach test` now dispatches through `mach mochitest --flavor` where supported. As part of testing this patch, it was discovered that `mach test` may have been broken for quite some time, as it was still referring to "test_file" arguments instead of "test_paths." This has been corrected.
testing/mach_commands.py
--- a/testing/mach_commands.py
+++ b/testing/mach_commands.py
@@ -63,39 +63,39 @@ TEST_SUITES = {
         'kwargs': {},
     },
     'check-spidermonkey': {
         'aliases': ('Sm', 'sm'),
         'mach_command': 'check-spidermonkey',
         'kwargs': {'valgrind': False},
     },
     'mochitest-a11y': {
-        'mach_command': 'mochitest-a11y',
-        'kwargs': {'test_file': None},
+        'mach_command': 'mochitest',
+        'kwargs': {'flavor': 'a11y', 'test_paths': None},
     },
     'mochitest-browser': {
         'aliases': ('bc', 'BC', 'Bc'),
         'mach_command': 'mochitest-browser',
-        'kwargs': {'test_file': None},
+        'kwargs': {'flavor': 'browser-chrome', 'test_paths': None},
     },
     'mochitest-chrome': {
-        'mach_command': 'mochitest-chrome',
-        'kwargs': {'test_file': None},
+        'mach_command': 'mochitest',
+        'kwargs': {'flavor': 'chrome', 'test_paths': None},
     },
     'mochitest-devtools': {
         'aliases': ('dt', 'DT', 'Dt'),
-        'mach_command': 'mochitest-browser --subsuite=devtools',
-        'kwargs': {'test_file': None},
+        'mach_command': 'mochitest-browser',
+        'kwargs': {'subsuite': 'devtools', 'test_paths': None},
     },
     'mochitest-ipcplugins': {
         'make_target': 'mochitest-ipcplugins',
     },
     'mochitest-plain': {
-        'mach_command': 'mochitest-plain',
-        'kwargs': {'test_file': None},
+        'mach_command': 'mochitest',
+        'kwargs': {'flavor': 'mochitest', 'test_paths': None},
     },
     'reftest': {
         'aliases': ('RR', 'rr', 'Rr'),
         'mach_command': 'reftest',
         'kwargs': {'test_file': None},
     },
     'reftest-ipc': {
         'aliases': ('Ripc',),
@@ -112,22 +112,23 @@ TEST_SUITES = {
         'mach_command': 'xpcshell-test',
         'kwargs': {'test_file': 'all'},
     },
 }
 
 for i in range(1, MOCHITEST_TOTAL_CHUNKS + 1):
     TEST_SUITES['mochitest-%d' %i] = {
         'aliases': ('M%d' % i, 'm%d' % i),
-        'mach_command': 'mochitest-plain',
+        'mach_command': 'mochitest',
         'kwargs': {
+            'flavor': 'mochitest',
             'chunk_by_dir': MOCHITEST_CHUNK_BY_DIR,
             'total_chunks': MOCHITEST_TOTAL_CHUNKS,
             'this_chunk': i,
-            'test_file': None,
+            'test_paths': None,
         },
     }
 
 TEST_HELP = '''
 Test or tests to run. Tests can be specified by test suite name or alias.
 The following test suites and aliases are supported: %s
 ''' % ', '.join(sorted(TEST_SUITES))
 TEST_HELP = TEST_HELP.strip()