author | Dan Minor <dminor@mozilla.com> |
Tue, 29 Apr 2014 10:22:50 -0400 | |
changeset 180701 | 9e05b74b44a7e4bc62509298f85d4f38ff475cec |
parent 180700 | 66eeca26b328a12915363ebfea8b0a8c90c21a27 |
child 180702 | b7a8d76c6685d02f4831c33b97011872bfa2c2ab |
push id | 42858 |
push user | dminor@mozilla.com |
push date | Tue, 29 Apr 2014 14:51:00 +0000 |
treeherder | mozilla-inbound@9e05b74b44a7 [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | mshal |
bugs | 992887 |
milestone | 32.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
|
--- a/testing/mach_commands.py +++ b/testing/mach_commands.py @@ -57,20 +57,20 @@ TEST_SUITES = { 'mach_command': 'crashtest-ipc', 'kwargs': {'test_file': None}, }, 'jetpack': { 'aliases': ('J',), 'mach_command': 'jetpack-test', 'kwargs': {}, }, - 'jittest': { - 'aliases': ('Jit', 'jit'), - 'mach_command': 'jittest', - 'kwargs': {'test_file': None}, + 'check-spidermonkey': { + 'aliases': ('Sm', 'sm'), + 'mach_command': 'check-spidermonkey', + 'kwargs': {'valgrind': False}, }, 'mochitest-a11y': { 'mach_command': 'mochitest-a11y', 'kwargs': {'test_file': None}, }, 'mochitest-browser': { 'aliases': ('bc', 'BC', 'Bc'), 'mach_command': 'mochitest-browser', @@ -211,27 +211,46 @@ class MachCommands(MachCommandBase): self.log(logging.ERROR, 'cppunittests', {'exception': str(e)}, 'Caught exception running cpp unit tests: {exception}') result = False return 0 if result else 1 @CommandProvider -class JittestCommand(MachCommandBase): - @Command('jittest', category='testing', description='Run jit-test tests.') +class CheckSpiderMonkeyCommand(MachCommandBase): + @Command('check-spidermonkey', category='testing', description='Run SpiderMonkey tests.') @CommandArgument('--valgrind', action='store_true', help='Run jit-test suite with valgrind flag') - def run_jittest(self, **params): + def run_checkspidermonkey(self, **params): import subprocess import sys + bin_suffix = '' if sys.platform.startswith('win'): - js = os.path.join(self.bindir, 'js.exe') - else: - js = os.path.join(self.bindir, 'js') - cmd = [os.path.join(self.topsrcdir, 'js', 'src', 'jit-test', 'jit_test.py'), - js, '--no-slow', '--no-progress', '--tinderbox', '--tbpl'] + bin_suffix = '.exe' + + js = os.path.join(self.bindir, 'js%s' % bin_suffix) + + print('Running jit-tests') + jittest_cmd = [os.path.join(self.topsrcdir, 'js', 'src', 'jit-test', 'jit_test.py'), + js, '--no-slow', '--tbpl'] + if params['valgrind']: + jittest_cmd.append('--valgrind') + + jittest_result = subprocess.call(jittest_cmd) - if params['valgrind']: - cmd.append('--valgrind') + print('running jstests') + jstest_cmd = [os.path.join(self.topsrcdir, 'js', 'src', 'tests', 'jstests.py'), + js, '--tbpl'] + jstest_result = subprocess.call(jstest_cmd) - return subprocess.call(cmd) + print('running jsapi-tests') + jsapi_tests_cmd = [os.path.join(self.bindir, 'jsapi-tests%s' % bin_suffix)] + jsapi_tests_result = subprocess.call(jsapi_tests_cmd) + + print('running check-style') + check_style_cmd = [sys.executable, os.path.join(self.topsrcdir, 'config', 'check_spidermonkey_style.py')] + check_style_result = subprocess.call(check_style_cmd, cwd=os.path.join(self.topsrcdir, 'js', 'src')) + + all_passed = jittest_result and jstest_result and jsapi_tests_result and check_style_result + + return all_passed