Commit Graph

160 Commits

Author SHA1 Message Date
Mihai Alexandru Michis
60087ba0c3 Bug 1573585 - Fix unindented block. a=lint-fix CLOSED TREE 2019-08-23 00:05:01 +03:00
Edwin Gao
ca724248e4 Bug 1573585 - ensure debugger name is prefixed to the application command when using mach test r=gbrown,Ehsan
If test is run using the `mach test` harness, populate the `extra_args` with `--debugger=<name>` that is expected by the underlying harnesses (`wpt,`, `mochitest`)  in order to maintain compatibility.

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

--HG--
extra : moz-landing-system : lando
2019-08-22 20:51:11 +00:00
Geoff Brown
fd801b55c9 Bug 1572794 - Add summary and filter-values regex to 'mach test-info report'; r=jmaher
Optional summary provides a convenient synopsis of matching tests. filter-values regex
was requested for in bug 1568638, like --filter-values='(?<!!)fission'.

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

--HG--
extra : moz-landing-system : lando
2019-08-20 16:19:40 +00:00
Geoff Brown
16c83acf2b Bug 1572794 - Add --no-component-report option to 'mach test-info report'; r=jmaher
Keep the existing report format by default, but provide an option to generate a
report that is not broken down by component.

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

--HG--
extra : moz-landing-system : lando
2019-08-10 21:52:39 +00:00
Geoff Brown
9207b87bbb Bug 1572794 - Add 'flavor' and 'subsuite' args for 'mach test-info report'; r=jmaher
These were already supported by the test resolver; let's use them. More tweaks planned...

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

--HG--
extra : moz-landing-system : lando
2019-08-09 17:31:56 +00:00
Axel Hecht
c3a71a9957 Bug 1321281, add test framework for Fluent migration recipes, r=flod,ahal
Basic test infrastructure for Fluent migration recipes, automate creating
a reference from recipe data, and running the recipe dry and wet.

There are no hard failures for diffs, as it might just be OK.

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

--HG--
extra : moz-landing-system : lando
2019-08-08 11:54:30 +00:00
Geoff Brown
bbd039411d Bug 1404472 - Add mach subcommand for per-component test-info report; r=jmaher
This provides the basic functionality, but certainly not all the bells and whistles. Future work may add summaries and totals, better reftest support, better web-platform support, more flexible filtering, etc.

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

--HG--
extra : moz-landing-system : lando
2019-07-31 09:21:59 +00:00
Edwin Gao
a1cc4534a7 Bug 1519369 - support 'debugger' parser argument for mach test command r=ahal,gbrown
Differential Revision: https://phabricator.services.mozilla.com/D39229

--HG--
extra : moz-landing-system : lando
2019-07-26 15:18:18 +00:00
Andrew Halberstadt
3336efcb3f Bug 1473498 - Fixing Py3 compatibility errors reachable from testing/mach_commands.py r=gbrown
Differential Revision: https://phabricator.services.mozilla.com/D37762

--HG--
extra : moz-landing-system : lando
2019-07-16 01:21:55 +00:00
Andrew Halberstadt
3486ba642c Bug 1563797 - Use 'backports.shutil_which' instead of 'which' across the tree r=Callek
Differential Revision: https://phabricator.services.mozilla.com/D37097

--HG--
extra : moz-landing-system : lando
2019-07-11 14:03:39 +00:00
Jan de Mooij
ae0157f590 Bug 1562129 part 2 - Add --blinterp-eager to jit-test 'all' configuration. r=sfink
To not make jstests even slower, this adds --jitflags=jstests and uses it for
jstests in automation. For jstests we can use fewer jit configurations than
for jit-tests.

This also removes the bigint and bigintdebug autospider variants. BigInt is now
enabled by default so we no longer need the configure flag etc.

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

--HG--
extra : moz-landing-system : lando
2019-07-08 11:22:04 +00:00
Kartikaya Gupta
bb83950948 Bug 1558598 - Force WebRender on or off in the cppunit harness. r=ahal
Also adds it to the mach command, which is a little weird, because the
mach command doesn't expose the option but does parse it via the cpp unit
argument parser. So I just exposed it on the mach command and after that
it Just Works for mach.

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

--HG--
extra : moz-landing-system : lando
2019-06-29 09:49:23 +00:00
Geoff Brown
694a310a53 Bug 1558221 - Update 'mach test-info long-tasks'; r=jmaher
Follow-up on ekyle's kind suggestion. I also found the type of some of the
returned data has changed, producing incorrect zero counts. A simple type
conversion gets everything working again:

$ ./mach test-info long-tasks

Tasks nearing their max-run-time on mozilla-central,mozilla-inbound,autoland between 2019-06-03 and 2019-06-10
test-linux64-asan/opt-web-platform-tests-e10s-10       : 52 of 212 runs (24.0%) exceeded 90% of max-run-time (7200 s)
test-linux64/debug-telemetry-tests-client-e10s         : 34 of 211 runs (16.0%) exceeded 90% of max-run-time (600 s)
test-linux64-asan/opt-telemetry-tests-client-e10s      : 76 of 696 runs (10.0%) exceeded 90% of max-run-time (600 s)

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

--HG--
extra : moz-landing-system : lando
2019-06-10 17:40:33 +00:00
Aaron Klotz
104c07093b Bug 1238305: Modify cppunittests to look up breakpad symbols for logged stack traces; r=ted
--HG--
extra : rebase_source : 159c245748d0192207ffa97465e254ea1a1538e2
2019-05-03 13:00:46 -06:00
Chris Manchester
caa48376ad Bug 1547380 - Reject attempts to run the rusttests command from artifact builds. r=nalexander
Differential Revision: https://phabricator.services.mozilla.com/D29436

--HG--
extra : moz-landing-system : lando
2019-04-30 23:03:14 +00:00
Brian Grinstead
8ca66379e9 Bug 1547996 - Fix mochitest-browser-chrome with mach addtest;r=ahal
Differential Revision: https://phabricator.services.mozilla.com/D29364

--HG--
extra : moz-landing-system : lando
2019-04-30 15:20:51 +00:00
Geoff Brown
b57f56b05d Bug 1445677 - Fix 'mach test-info' platform handling; r=jmaher
The format of platform and type data seems to have evolved over time; these
changes seem to handle the new formats well.

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

--HG--
extra : moz-landing-system : lando
2019-04-25 09:20:06 +00:00
Andrew Halberstadt
48648a7344 Bug 1523303 - Align mozharness suite names with the ones in 'moztest.resolve', r=gbrown
This officially makes 'moztest.resolve' the source of truth when it comes to
suite names. It aligns that file with the names used in both the
desktop_unittest and android_emulator_unittest scripts.

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

--HG--
extra : moz-landing-system : lando
2019-04-22 22:32:34 +00:00
James Graham
7b45ebc476 Bug 1543244 - Refactor mach addtest support, r=ahal,bgrins
Add addtest support for per-suite arguments and multiple files. Also
support opening the created test in an editor. This allowed supporting
the wpt suite and replaces `mach wpt-create`.

 # Create a wpt test
 ./mach addtest testing/web-platform/tests/accelerometer/test.html

 # Create a wpt reftest
 ./mach addtest --suite wpt-reftesttesting/web-platform/tests/css/example.html --ref example-ref.html

The files created will be opened in the default editor if --editor is
supplied or a specified editor if the argument is given a value.

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

--HG--
extra : moz-landing-system : lando
2019-04-11 09:44:32 +00:00
Julian Descottes
28c84500a6 Bug 1543007 - Restore ./mach test command;r=pbro
Differential Revision: https://phabricator.services.mozilla.com/D26661

--HG--
extra : moz-landing-system : lando
2019-04-09 09:22:22 +00:00
Brian Grinstead
05f5ec26a4 Bug 1540285 - Add a test generator script into ./mach addtest r=ahal
Instead of:
perl gen_template.pl -b=123456 --type=plain > path/to/test_bug123456.html

You can do:
./mach addtest --suite="mochitest-plain" > path/to/test_bug123456.html

But you can also pass in a new file path and let it guess the suite/doc:

```
# mochitest-chrome tests
./mach addtest js/xpconnect/tests/chrome/test_chrome.html
./mach addtest js/xpconnect/tests/chrome/test_chrome.xhtml
./mach addtest js/xpconnect/tests/chrome/test_chrome.xul

# mochitest-plain tests
./mach addtest js/xpconnect/tests/mochitest/test_plain.html
./mach addtest js/xpconnect/tests/mochitest/test_plain.xhtml
./mach addtest js/xpconnect/tests/mochitest/test_plain.xul

# mochitest-browser tests
./mach addtest browser/base/content/test/alerts/browser_foo.js

# xpcshell tests
./mach addtest browser/components/extensions/test/xpcshell/test_xpcshell.js
```

This also changes the mochitest template files in the following ways:
- removes the bug # boilerplate
- remove some unnecessary attributes in the template
- removes the th.template
- adds the browser.template for browser-chrome tests

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

--HG--
rename : testing/mochitest/static/chrome.template.txt => testing/mochitest/static/chromehtml.template.txt
rename : testing/mochitest/static/test.template.txt => testing/mochitest/static/plainhtml.template.txt
rename : testing/mochitest/static/xhtml.template.txt => testing/mochitest/static/plainxhtml.template.txt
rename : testing/mochitest/static/xul.template.txt => testing/mochitest/static/plainxul.template.txt
extra : moz-landing-system : lando
2019-04-08 19:09:42 +00:00
Geoff Brown
fa1f40ea6a Bug 1500995 - Allow for missing 'failures' data in 'mach test-info'; r=me,a=test-only 2018-12-21 14:18:15 -07:00
Chris Manchester
b78d8dbce3 Bug 1505859 - Implement a mach wrapper for rusttests. r=firefox-build-system-reviewers,ted
Differential Revision: https://phabricator.services.mozilla.com/D11515

--HG--
extra : moz-landing-system : lando
2018-11-10 15:00:28 +00:00
Geoff Brown
79f5bdc311 Bug 1481449 - Require at least one test argument for 'mach test'; r=ahal 2018-08-31 09:59:07 -06:00
Geoff Brown
ee452067ce Bug 1329286 - Remove 'mach find-test-chunk'; r=ahal 2018-08-27 07:19:02 -06:00
Geoff Brown
24afcca748 Bug 1469720 - Add a 'mach test-info' subcommand to find long-running tasks; r=jmaher 2018-08-07 10:05:37 -06:00
Andrew Halberstadt
44f4128a40 Bug 1477276 - Fix regression preventing |mach help| without an objdir r=bhearsum
Differential Revision: https://phabricator.services.mozilla.com/D2267

--HG--
extra : moz-landing-system : lando
2018-07-20 14:58:06 +00:00
Geoff Brown
dfb845682a Bug 1476363 - Add --show-tasks support to 'mach test-info'; r=jmaher 2018-07-17 12:54:19 -06:00
Ms2ger
3787678d13 Bug 1460546 - Add a mach jstests command; r=dminor 2018-07-05 14:42:52 +02:00
Andrew Halberstadt
851c87fc61 Bug 1445975 - Add a basic mach command for running jsshell benchmarks, r=jmaher
Run with:
./mach jsshell-bench ares6

This requires a non-artifact build with ac_add_options --enable-js-shell. Otherwise,
a custom JS shell can be specified with --binary.

MozReview-Commit-ID: C8WAxG9pIkk

--HG--
extra : rebase_source : 99163261b771bfb2f903892f4c1260c8b241ce71
2018-05-15 14:41:16 -04:00
Jan de Mooij
d047348566 Bug 1063728 - Run SpiderMonkey style checkers as part of the build instead of make check. r=chmanchester 2018-04-26 09:09:51 +02:00
Jan de Mooij
2c4c4c3296 Bug 1064316 part 3 - Fix |mach check-spidermonkey| to use correct cwd. r=gps 2018-04-24 16:17:50 +02:00
Andrew Halberstadt
20f38147c2 Bug 1445624 - [test] Make sure verbose logging is enabled when running a single test, r=gbrown
This sets verbose=True (used by the mach formatter) and compact=False (used by tbplformatter) if
only a single test is specified with either |mach test| or |mach mochitest|.

This way all TEST_STATUS and log lines will be visible when developers are writing a new test.

MozReview-Commit-ID: 2nuKs9DLnx0

--HG--
extra : rebase_source : 1fc594b465a2a94dfcd85d56d042969af47f6f65
2018-03-19 16:04:02 -04:00
Andrew Halberstadt
be2e6d661c Bug 1443557 - Start using the 'mach' formatter by default in |mach test| and |mach mochitest|, r=gbrown
This was originally supposed to be fixed in bug 1421799, but I either forgot to
switch the flag, or accidentally clobbered it while resolving conflicts.

MozReview-Commit-ID: Im8OKbswEf0

--HG--
extra : rebase_source : 1104969aca56b62f8f302225fd11a509a73a3960
2018-03-12 16:46:53 -04:00
Andrew Halberstadt
af02603e3d Bug 1440405 - Fix faulty assumption that only one log handler can be installed in |mach test/mochitest|, r=froydnj
MozReview-Commit-ID: AzKLAgW5agx

--HG--
extra : rebase_source : 34cebcc49435a3c5875b4805d00aeff2c7530b9c
2018-02-23 09:40:06 -05:00
Andrew Halberstadt
f249b70e43 Bug 1437912 - [moztest] Map flavors and subsuites to a suite definition, r=gbrown
The end goal here is to be able to use |mach try fuzzy <path>| with tests that
belong to a subsuite. To do this, we need a unique 'task_regex' value for each
subsuite so that we can map a test path back to a set of tasks.

This removes the TEST_FLAVORS dict (which was mostly just a redefinition of the
data in TEST_SUITES), and instead provides two new private mappings:

<flavor> -> suite definition
(<flavor>, <subsuite>) -> suite definition

To retrieve a suite definition given a flavor/subsuite, consumers can now call
get_suite_definition.

MozReview-Commit-ID: 2pe1v1IHUVy

--HG--
extra : rebase_source : 6fff947ba214112ccf16c894174a6a0e2487111a
2018-02-13 14:16:46 -05:00
Andrew Halberstadt
0c637cdc6c Bug 1421799 - [test] Add mozlog logging arguments to |mach test| and |mach mochitest| r=gbrown
MozReview-Commit-ID: CaysVHzNTWo

--HG--
extra : rebase_source : f6e1375e1de7e80f2583ac89f78ff90afe01934f
2017-12-06 17:29:23 -05:00
Sebastian Hengst
e6dbbae0aa Backed out 5 changesets (bug 1421799) for failing firefox ui functional tests. r=backout on a CLOSED TREE
Backed out changeset f9f32474fdaf (bug 1421799)
Backed out changeset 18b4fa241936 (bug 1421799)
Backed out changeset 88dca5c8cfac (bug 1421799)
Backed out changeset 8c1f1ab754a5 (bug 1421799)
Backed out changeset e028f677bc80 (bug 1421799)
2018-01-03 20:21:28 +02:00
Andrew Halberstadt
89c4f8acbc Bug 1421799 - [test] Add mozlog logging arguments to |mach test| and |mach mochitest| r=gbrown
MozReview-Commit-ID: CaysVHzNTWo

--HG--
extra : rebase_source : 005949ca4a91b4610837a7dd041f26a25559049a
2017-12-06 17:29:23 -05:00
Dorel Luca
61983e9ada Backed out 5 changesets (bug 1421799) for failing browser-chrome on Linux and OSX and for failing autophone-mochitest on Android r=backout on a CLOSED TREE
Backed out changeset 7fb20bced076 (bug 1421799)
Backed out changeset 629e467a07be (bug 1421799)
Backed out changeset 2de335c0287a (bug 1421799)
Backed out changeset afe14ec646ab (bug 1421799)
Backed out changeset bbe4d2292f86 (bug 1421799)
2017-12-14 15:41:22 +02:00
Andrew Halberstadt
b7c836bd6d Bug 1421799 - [test] Make the 'mach' formatter the default when running |mach test| and |mach mochitest| r=gbrown
MozReview-Commit-ID: 17ENkMhLTYc

--HG--
extra : rebase_source : 9d3bda2855cb6a966e53c19c1443b5952da5a4a9
2017-12-06 14:13:40 -05:00
Andrew Halberstadt
d27d62788b Bug 1421799 - [test] Add mozlog logging arguments to |mach test| and |mach mochitest| r=gbrown
MozReview-Commit-ID: CaysVHzNTWo

--HG--
extra : rebase_source : a5ffb00e0fae1a70a6d01d629710db6ea042260f
2017-12-06 17:29:23 -05:00
Andrew Halberstadt
bc48fbb9ae Bug 1209463 - [mozlog] Add a 'summary_on_shutdown' attribute to MachFormatter, r=jgraham
When 'summary_on_shutdown' is True (which is the case for |mach test| and |mach
mochitest|), BaseSummaryFormatters will save the summary information until the
'shutdown' action is received at the end of the logger's lifetime.

Summary information will no longer be dumped on 'suite_end'.

MozReview-Commit-ID: HKtVr5PxfOy

--HG--
extra : rebase_source : f350f09111deb510b27a4e55797243dda3160869
2017-11-29 12:02:19 -05:00
Andrew Halberstadt
3e46924759 Bug 1209463 - [test] Use a common logger across suites from |mach test| and other test commands, r=gbrown
In order for |mach test| and |mach mochitest| to log an overall summary,
every test harness invocation they make needs to use the same structured
logger (otherwise the affected suite will be missing from the summary).

MozReview-Commit-ID: 8LJw7r8SItk

--HG--
extra : rebase_source : 1417dce3817bae94ad61a5250065c6cbc35857e4
2017-11-23 13:04:19 -05:00
Sebastian Hengst
a353221537 merge mozilla-inbound to mozilla-central. r=merge a=merge 2017-11-09 00:00:16 +02:00
Geoff Brown
74ddbdda93 Bug 1414960 - Improve formatting of |mach test-info| output; r=jmaher 2017-11-08 09:32:09 -07:00
Andrew Halberstadt
52dad304bf Bug 1414399 - [moztest] Refactor |mach test|'s resolving logic into moztest.resolve r=gps
The code in |mach test| for test resolving, should get merged with the TestResolver
class in moztest.resolve. This way it can be shared with other modules and we'll
have a single canonical place for all our test resolving logic.

MozReview-Commit-ID: IHRXXi5mB4G

--HG--
extra : rebase_source : 6f96d06412ab8fa152ac5d9bdd15acbcdc9695c4
2017-11-08 09:59:51 -05:00
Andrew Halberstadt
a69182174e Bug 1414399 - [mozbuild/moztest] Move mozbuild.testing.TestResolver to moztest.resolve r=gps
The TestMetadata and TestResolver classes aren't technically part of the build
system. The only connection is that they consume some build system output.

The next patch in this series is going to be merging in a bunch of other test
resolving logic from other parts of the tree. Moving this out first allows us
to keep that extra logic out of mozbuild.

MozReview-Commit-ID: 1eq4SjFVCyW

--HG--
rename : python/mozbuild/mozbuild/test/test_testing.py => testing/mozbase/moztest/tests/test_resolve.py
extra : rebase_source : 7ff11f9ec455547533082d20cb5371845f7a4f21
2017-11-06 08:41:42 -05:00
Attila Craciun
7bcf901c3b Merge inbound to mozilla-central r=merge a=merge 2017-10-25 12:30:28 +03:00
Geoff Brown
5facbdc255 Bug 1410714 - Help mach tests find adb when running Android tests; r=jmaher 2017-10-24 15:17:25 -06:00