Commit graph

121 commits

Author SHA1 Message Date
Andrey Bienkowski
888618300d Bug 1714376 - Replace a number of "exception.message" usages. r=mhentges,jgraham
Differential Revision: https://phabricator.services.mozilla.com/D116723
2021-06-08 15:50:10 +00:00
Dorel Luca
f021feb29f Backed out changeset 68f73772f51e (bug 1714376) for Xpcom failures in builds/worker/checkouts/gecko/xpcom/idl-parser/xpidl/runtests.py. CLOSED TREE 2021-06-04 02:19:33 +03:00
Andrey Bienkowski
a7a4542e20 Bug 1714376 - Replace a number of "exception.message" usages. r=mhentges,jgraham
Differential Revision: https://phabricator.services.mozilla.com/D116723
2021-06-03 20:08:51 +00:00
Sebastian Hengst
8dca332465 Bug 1711652 - Fix broken call of run_web_platform_tests() due to missing command context: Fix typo. r=me CLOSED TREE 2021-05-18 13:26:57 +02:00
Henrik Skupin
fbc946b53b Bug 1711652 - Fix broken call of run_web_platform_tests() due to missing command context. r=jgraham
Differential Revision: https://phabricator.services.mozilla.com/D115345
2021-05-18 11:18:38 +00:00
Alex Lopez
455d9a088b Bug 1696251 - Pass MachCommandBase object as first argument for Mach Commands. r=mhentges,remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers
As an intermediate step to allow mach commands as standalone functions, the MachCommandBase
subclass instance that currently corresponds to self has to be made available as a separate
argument (named command_context).

Differential Revision: https://phabricator.services.mozilla.com/D109650
2021-05-17 16:15:58 +00:00
Butkovits Atila
2e34e363b9 Backed out 2 changesets (bug 1696251) for causing js-bench-sm failures. CLOSED TREE
Backed out changeset 1c84c9a34575 (bug 1696251)
Backed out changeset e169193b7423 (bug 1696251)
2021-04-23 02:53:36 +03:00
Alex Lopez
d1a82b8092 Bug 1696251 - Pass MachCommandBase object as first argument for Mach Commands. r=mhentges,remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers
As an intermediate step to allow mach commands as standalone functions, the MachCommandBase
subclass instance that currently corresponds to self has to be made available as a separate
argument (named command_context).

Differential Revision: https://phabricator.services.mozilla.com/D109650
2021-04-22 18:56:15 +00:00
Cosmin Sabou
785f9b8a87 Backed out changeset d4a5d8567977 (bug 1696251) for non-unified build bustages. CLOSED TREE 2021-04-19 19:43:31 +03:00
Alex Lopez
75dfe35468 Bug 1696251 - Pass MachCommandBase object as first argument for Mach Commands. r=mhentges,remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers
As an intermediate step to allow mach commands as standalone functions, the MachCommandBase
subclass instance that currently corresponds to self has to be made available as a separate
argument (named command_context).

Differential Revision: https://phabricator.services.mozilla.com/D109650
2021-04-19 16:15:11 +00:00
James Graham
c186b32f83 Bug 1695972 - Add a mach command for finding fission-specific regressions in wpt, r=kashav,jmaher
This adds a `mach wpt-fission-regressions` command that uses the wpt
expectation data to look for tests which have a worse result in
fission. With the `--all-json=<path>` argument it will output a JSON
file containing details of all the regressions. With the
`--untriaged=<path>` argument it will output a file containing a list
of failures that have not yet been triaged.

It also adds a try job to produce those files as artifacts whenever
wpt metadata is changed.

The actual implementation is based on reading the wpt expectation data
with sample run_info values corresponding to the configurations in
which we have fission enabled, but with the "fission" property set to
False (to get a baseline result) and True (to get a with-fission
result) and then comparing the resulting expectations.

The implemenation is pretty suboptimal performance wise since we end
up reading the metadata once per configuration i.e. 6 times, and this
is slow. It could be optimised by using the conditional metadata
backend, reading it once, and then evaluating per
configuration. However that would require a little more work and the
presumption is that this will be shortlived until fission becomes the
default configuration.

Differential Revision: https://phabricator.services.mozilla.com/D106954
2021-03-02 21:19:00 +00:00
James Graham
23a302cbe4 Bug 1678663 - Support passing adb binary in to wptrunner, r=bc
Differential Revision: https://phabricator.services.mozilla.com/D99254
2020-12-14 14:10:41 +00:00
James Graham
fddc22a7d0 Bug 1676655 - Enable additional root paths when running mach wpt-serve, r=karlcow
This replicates the logic in
testing/web-platform/tests/tools/wptrunner/wptrunner/environment.py to
ensure that all the configured URL base paths are added to the
wptserve router configuration when starting via mach wpt-serve.

Differential Revision: https://phabricator.services.mozilla.com/D96723
2020-11-12 10:26:14 +00:00
Ricky Stewart
02a7b4ebdf Bug 1654103: Standardize on Black for Python code in mozilla-central.
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-26 18:34:53 +00:00
Bogdan Tara
da1098d4aa Backed out 10 changesets (bug 1654103, bug 1672023, bug 1518999) for PanZoomControllerTest.touchEventForResult gv-junit failures CLOSED TREE
Backed out changeset ff3fb0b4a512 (bug 1672023)
Backed out changeset e7834b600201 (bug 1654103)
Backed out changeset 807893ca8069 (bug 1518999)
Backed out changeset 13e6b92440e9 (bug 1518999)
Backed out changeset 8b2ac5a6c98a (bug 1518999)
Backed out changeset 575748295752 (bug 1518999)
Backed out changeset 65f07ce7b39b (bug 1518999)
Backed out changeset 4bb80556158d (bug 1518999)
Backed out changeset 8ac8461d7bd7 (bug 1518999)
Backed out changeset e8ba13ee17f5 (bug 1518999)
2020-10-24 03:36:18 +03:00
Ricky Stewart
c0cea3b0fa Bug 1654103: Standardize on Black for Python code in mozilla-central. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-23 20:40:42 +00:00
Dorel Luca
1ff59cb7a3 Backed out changeset 7558c8821a07 (bug 1654103) for multiple failures. CLOSED TREE 2020-10-22 03:51:06 +03:00
Ricky Stewart
50762dacab Bug 1654103: Standardize on Black for Python code in mozilla-central. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-21 21:27:27 +00:00
James Graham
ec26b652e7 Bug 1668458 - Load specialPowers web extension in gecko-only wpt tests, r=jmaher,twisniewski,whimboo
Lack of support for specialPowers is often cited as a reason for
developers to write mochitests rather than wpt. Although using
specialPowers means that the tests can't be upstreamed, having it
available in gecko-only tests should reduce the need to write
mochitests and potentially means that a patch which previously would
be written with just mochitests would instead be written with just
wpt, a fraction of which would be unsuitable for sharing.

Nevertheless a gecko-only specialPowers-using test should be
considered the option of last resort when cross-browser APIs such as
testdriver aren't sufficient.

This patch installs the specialPowers extension when the path to the
XPI is provided via a --specialpowers-path command line argument. To
ensure this only happens for gecko-only tests, the url_base is added
to the Test object, and the firefox settings() method is updated to
contain a specialpowers setting, which uses the url_base of the test
to determine if this is a gecko-only test.

Because the extension has to be enabled using marionette, we also need
to route this setting through the to executor, along with the provided
XPI path.

Differential Revision: https://phabricator.services.mozilla.com/D92035
2020-10-06 14:01:24 +00:00
Bogdan Tara
50effb1629 Backed out changeset 5f2252c9e774 (bug 1668458) for wpt failures CLOSED TREE 2020-10-06 16:32:01 +03:00
James Graham
d248b39a61 Bug 1668458 - Load specialPowers web extension in gecko-only wpt tests, r=jmaher,twisniewski,whimboo
Lack of support for specialPowers is often cited as a reason for
developers to write mochitests rather than wpt. Although using
specialPowers means that the tests can't be upstreamed, having it
available in gecko-only tests should reduce the need to write
mochitests and potentially means that a patch which previously would
be written with just mochitests would instead be written with just
wpt, a fraction of which would be unsuitable for sharing.

Nevertheless a gecko-only specialPowers-using test should be
considered the option of last resort when cross-browser APIs such as
testdriver aren't sufficient.

This patch installs the specialPowers extension when the path to the
XPI is provided via a --specialpowers-path command line argument. To
ensure this only happens for gecko-only tests, the url_base is added
to the Test object, and the firefox settings() method is updated to
contain a specialpowers setting, which uses the url_base of the test
to determine if this is a gecko-only test.

Because the extension has to be enabled using marionette, we also need
to route this setting through the to executor, along with the provided
XPI path.

Differential Revision: https://phabricator.services.mozilla.com/D92035
2020-10-06 12:54:36 +00:00
Noemi Erli
112f24b054 Backed out 2 changesets (bug 1668458) for causing web platform test failures CLOSED TREE
Backed out changeset 8739d75e13dc (bug 1668458)
Backed out changeset e45a73a47c37 (bug 1668458)
2020-10-05 18:24:36 +03:00
James Graham
e30a02602c Bug 1668458 - Load specialPowers web extension in gecko-only wpt tests, r=jmaher,twisniewski
Lack of support for specialPowers is often cited as a reason for
developers to write mochitests rather than wpt. Although using
specialPowers means that the tests can't be upstreamed, having it
available in gecko-only tests should reduce the need to write
mochitests and potentially means that a patch which previously would
be written with just mochitests would instead be written with just
wpt, a fraction of which would be unsuitable for sharing.

Nevertheless a gecko-only specialPowers-using test should be
considered the option of last resort when cross-browser APIs such as
testdriver aren't sufficient.

This patch installs the specialPowers extension when the path to the
XPI is provided via a --specialpowers-path command line argument. To
ensure this only happens for gecko-only tests, the url_base is added
to the Test object, and the firefox settings() method is updated to
contain a specialpowers setting, which uses the url_base of the test
to determine if this is a gecko-only test.

Because the extension has to be enabled using marionette, we also need
to route this setting through the to executor, along with the provided
XPI path.

Differential Revision: https://phabricator.services.mozilla.com/D92035
2020-10-02 19:34:10 +00:00
Philipp Fischbeck
8d351c89b3 Bug 1622686 - Make testing/web-platform flake8 compliant. r=sylvestre,jgraham
This also enables py3 linting for testing/web-platform. The external testing/web-platform/tests is excluded from linting.

Differential Revision: https://phabricator.services.mozilla.com/D90744
2020-09-29 14:22:49 +00:00
James Graham
0116c32dbb Bug 1663653 - Make wptrunner use the same manifest for non-gecko products, r=whimboo
This utilises the fact that we can now specify the manifest
independently of the metadata path, which wasn't possible before. We
need to edit the default (i.e. Firefox) configuration to update the
metadata path (only) to point at something product-specific so we
don't end up using fx metadata for everything.

Differential Revision: https://phabricator.services.mozilla.com/D89461
2020-09-09 09:44:22 +00:00
James Graham
0d4af79641 Bug 1658296 - Add extra kwargs required by wpt run, r=maja_zf
Differential Revision: https://phabricator.services.mozilla.com/D86567
2020-08-10 19:21:44 +00:00
Andrew Halberstadt
d0fbcca0b6 Bug 985141 - [mozbuild] Remove leading underscore from MozbuildObject._activate_virtualenv, r=firefox-build-system-reviewers,perftest-reviewers,andi,AlexandruIonescu,rstewart
This function is used all across the tree and should be considered a public API.

Differential Revision: https://phabricator.services.mozilla.com/D85045
2020-07-28 16:06:10 +00:00
James Graham
89be8b0d1e Bug 1646801 - Fix mach test with wpt, r=ahal
Don't require setting include as an empty list. Use the subsuite name if known.

Differential Revision: https://phabricator.services.mozilla.com/D80500
2020-06-22 18:17:00 +00:00
James Graham
a52ec9b166 Bug 1628647 - Don't use preload-browser for local runs, r=maja_zf
Differential Revision: https://phabricator.services.mozilla.com/D70332

--HG--
extra : moz-landing-system : lando
2020-04-09 13:49:04 +00:00
Brendan Dahl
a1088aa304 Bug 1566930 - Default to auto install on the various android mach commands. r=gbrown,perftest-reviewers,whimboo,sparky
Differential Revision: https://phabricator.services.mozilla.com/D64230

--HG--
extra : moz-landing-system : lando
2020-03-13 20:48:52 +00:00
James Graham
1fb8660451 Bug 1613624 - Make it possible to disable system fonts in wpt, r=maja_zf
wpt previously required Ahem as a system font. That requirement is now
relaxed and installing fonts is only required in order to see bugs
that result from differences between the system font loader and the
webfont loader. Since installing fonts can cause problems on some
systems, make this possible to disable.

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

--HG--
extra : moz-landing-system : lando
2020-02-06 21:07:10 +00:00
Botond Ballo
abcab3d351 Bug 1599930 - Support --no-install for web platform tests. r=jgraham
Differential Revision: https://phabricator.services.mozilla.com/D55046

--HG--
extra : moz-landing-system : lando
2020-01-28 15:28:19 +00:00
James Graham
d13deb4671 Bug 1600695, Add mach wpt-test-paths command, r=dheiberg
This command takes a list of test ids and returns the list of test
files that correspond to those test ids. The mapping is one-to-many
between files and test ids i.e. a single file can generate many tests.

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

--HG--
extra : moz-landing-system : lando
2019-12-09 10:46:50 +00:00
Botond Ballo
83bfe6cee0 Bug 1590857 - Don't prompt to install Android app if the user is running 'mach install'. r=gbrown
Differential Revision: https://phabricator.services.mozilla.com/D54381

--HG--
extra : moz-landing-system : lando
2019-11-25 22:17:59 +00:00
Christian Holler
e13ae32f18 Bug 1589612 - Remove remaining lsan_dir from WPT mach command. r=jgraham
Differential Revision: https://phabricator.services.mozilla.com/D49721

--HG--
extra : moz-landing-system : lando
2019-10-18 10:02:52 +00:00
James Graham
f6819f7712 Bug 1583603 - Set formatter defaults correctly for mozlog, r=maja_zf
Gecko was trying to pass formatter options in by default, which
doesn't work if the user overrides the formatter. Instead pass in the
default options explicitly using the designed mechanism, which
previously wasn't exposed in wpt.

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

--HG--
extra : moz-landing-system : lando
2019-09-25 19:37:38 +00:00
James Graham
d4d66f19dc Bug 1571755 - Add a command for merging wpt metadata, r=maja_zf
This command is inteded to be usable as a git mergetool for the
specific case of merging ini files in a way that should always
succeed, produces reasonably likely output, but isn't reliably
correct.

The main use case is for the sync bot where we update metadata on
branches and experience conflicts when we also have changes on
master. We don't necessarily need to resolve these perfectly but we do
need to provide a resolution automatically since otherwise it blocks
syncs. Since the ini parser is in-tree we want to make this an in-tree
command that the sync can use to provide the resolution.

The general strategy is that we want to prefer the "new" metadata
where possible. This won't always be correct e.g. if a test got fixed
on master and simultaneously got edited to go from TIMEOUT to FAIL in
a browser without the fix. But it's not a bad approximation (and
generally a human will struggle to do the merge better by hand, so we
have to assume later try jobs will fix things).

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

--HG--
extra : moz-landing-system : lando
2019-08-09 17:48:53 +00:00
Geoff Brown
f7b0420fd4 Bug 1570051 - Minor updates to android mach commands; r=bc
Various cleanup:
 - remove extraneous calls to grant_runtime_permissions
 - remove unused legacy jimdb support code
 - remove "This may take a while" logging
 - emphasize x86/x86_64 capabilities of emulator

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

--HG--
extra : moz-landing-system : lando
2019-08-03 01:52:39 +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
Maja Frydrychowicz
b867fd4d06 Bug 1560023 - Rename wpt product fennec to firefox_android; r=jgraham,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D36630

--HG--
rename : testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/fennec.py => testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/firefox_android.py
extra : moz-landing-system : lando
2019-07-09 18:10:03 +00:00
Geoff Brown
00c7fc4efb Bug 1560073 - Change default android package name for most mach test commands; r=snorp,nalexander,maja_zf
Use the geckoview TestRunnerActivity, org.mozilla.geckoview.test, by default
for all types of mochitests, reftests, and web-platform tests. TRA is already
the default for gtest and geckoview-junit. Fennec, based on ANDROID_PACKAGE_NAME,
remains the default for robocop and marionette-test and I have no plans to
change those. There is a related issue for xpcshell-test -- not the package
name, but the default apk -- but I am reluctant to handle that until bug 1553225
is resolved.

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

--HG--
extra : moz-landing-system : lando
2019-06-26 02:34:49 +00:00
James Graham
dff5223533 Bug 1557079 - Add mach command for running wpt unittests, r=maja_zf,nikkis
./mach wpt-unittest command will run tox in testing/web-platform/tests/tools
and testing/web-platform/tests/tools/wptrunner. It does some hacking to update
the requirements.txt files so that we use the in-tree versions of packages
rather than updating from pypi; this involves temporarily rewriting the files
since I couldn't figure out a good way to get tox to install something different.

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

--HG--
extra : moz-landing-system : lando
2019-06-13 14:24:25 +00:00
Geoff Brown
50a156acb9 Bug 1556517 - Avoid attribute error when installing geckoview from 'mach wpt'; r=KWierso
Differential Revision: https://phabricator.services.mozilla.com/D33583

--HG--
extra : moz-landing-system : lando
2019-06-04 00:11:18 +00:00
James Graham
4490fed96d Bug 1555212 - Make wpt --product install the dependencies in the mach layer, r=ato
This avoids a mismatch in the available arguments between upstream pip and
the version vendored into m-c at the cost of the code being more liable
to break when upstream changes.

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

--HG--
extra : moz-landing-system : lando
2019-05-29 11:30:45 +00:00
James Graham
f2abc2c651 Bug 1543073 - Add mach wpt-serve for running the wpt server, r=ahal
Differential Revision: https://phabricator.services.mozilla.com/D26705

--HG--
extra : moz-landing-system : lando
2019-04-11 16:47:58 +00:00
James Graham
157b19df11 Bug 1536804 - Add a mach command to summarise wpt metadata, r=ato
This parses the metadata files without evaluating the conditional
expressions, producing a JSON summary file in which each possible
condition is represented as a string.

Not all data from the metadata files appears in the summary, only
exceptional cases likely to be of interest to engineers and unlikely
to be on wpt.fyi e.g. tests that have lsan leaks or tests that crash,
not just tests that fail. This is intended to keep the filesize down.

Depends on D24177

Depends on D24177

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

--HG--
extra : moz-landing-system : lando
2019-04-11 16:40:07 +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
Bogdan Tara
f81aa92481 Backed out 3 changesets (bug 1536804) for /css/css-* failures CLOSED TREE
Backed out changeset e8758002d7d4 (bug 1536804)
Backed out changeset 795287b1e059 (bug 1536804)
Backed out changeset 9a680e886248 (bug 1536804)
2019-03-26 18:41:16 +02:00
James Graham
dd074e8a30 Bug 1536804 - Add a mach command to summarise wpt metadata, r=ato
This parses the metadata files without evaluating the conditional
expressions, producing a JSON summary file in which each possible
condition is represented as a string.

Not all data from the metadata files appears in the summary, only
exceptional cases likely to be of interest to engineers and unlikely
to be on wpt.fyi e.g. tests that have lsan leaks or tests that crash,
not just tests that fail. This is intended to keep the filesize down.

Depends on D24177

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

--HG--
extra : moz-landing-system : lando
2019-03-21 12:44:34 +00:00
James Graham
bf4d3018bc Bug 1511764 - Fixup launching Chrome from ./mach wpt, r=whimboo
Differential Revision: https://phabricator.services.mozilla.com/D19486

--HG--
extra : moz-landing-system : lando
2019-02-12 14:32:09 +00:00