Bug 1403012 - Fix TypeError when running python unittests via |mach test|, r=gbrown
authorAndrew Halberstadt <ahalberstadt@mozilla.com>
Fri, 12 Jan 2018 11:22:58 -0500
changeset 399050 83ce7df5790dbd42dc064f9f0d4af7874dbc193a
parent 399049 022ee7de00985e0cde5ea633de5dbec4577715c9
child 399051 78576ff98660a4d2b8ad07c043dfbc80be5b0399
push id57985
push userahalberstadt@mozilla.com
push dateFri, 12 Jan 2018 19:30:12 +0000
treeherderautoland@83ce7df5790d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgbrown
bugs1403012
milestone59.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 1403012 - Fix TypeError when running python unittests via |mach test|, r=gbrown Mach test now creates a structured logger and passes it down into all of the various test harnesses. Except |mach python-test| doesn't use structured logging yet, so the argument is not expected. For now, just accept **kwargs and ignore the logger. Eventually we'll want to get python tests to use structured logging, and we can use it at that point. MozReview-Commit-ID: 8LwdbgI0vqR
python/mach_commands.py
--- a/python/mach_commands.py
+++ b/python/mach_commands.py
@@ -91,17 +91,18 @@ class MachCommands(MachCommandBase):
             mozfile.remove(tempdir)
 
     def run_python_tests(self,
                          tests=[],
                          test_objects=None,
                          subsuite=None,
                          verbose=False,
                          stop=False,
-                         jobs=1):
+                         jobs=1,
+                         **kwargs):
         self._activate_virtualenv()
 
         def find_tests_by_path():
             import glob
             files = []
             for t in tests:
                 if t.endswith('.py') and os.path.isfile(t):
                     files.append(t)