Files
tubestation/testing
Rob Wu a6a01b073b Bug 1936281 - Default to retry=False when running xpcshell tests locally r=jmaher
The "retry" flag of XPCShellTestThread is currently only used to opt out
of retry, e.g. when the test is retried or when run with `--verify`.

All uses of the retry flag assumes that the test will be retried on
failure if retry=True. In bug 1790085, another way to opt out of retry
was added: when tests are run sequentially, the absence of the
MOZ_AUTOMATION environment variable implies opting out of retry for
sequential tests. Consequently, test results were suppressed (by the
retry=True flag) without actually retrying (due to the MOZ_AUTOMATION
check).

This patch fixes the issue by setting the retry flag to False when
MOZ_AUTOMATION is not set. This results in the following changes:

- `./mach xpcshell-test --self-test` passes locally instead of failing.

- `./mach xpcshell-test path/to/tests` without `--sequential` now report
  results without retrying first. To get the old behavior, run tests
  with `MOZ_AUTOMATION=1`

Differential Revision: https://phabricator.services.mozilla.com/D231689
2024-12-10 20:57:52 +00:00
..

Common testing tools for mozilla codebase projects, test suite definitions
for automated test runs, tests that don't fit anywhere else, and other fun
stuff