Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 2a77f5e5eb97e190d708ca2ae6fc4cb3b7a27679
https://github.com/WebKit/WebKit/commit/2a77f5e5eb97e190d708ca2ae6fc4cb3b7a27679
Author: Marta Darbinyan <[email protected]>
Date: 2026-08-24 (Mon, 24 Aug 2026)
Changed paths:
M Tools/Scripts/run-api-tests
M Tools/Scripts/webkitpy/api_tests/manager.py
M Tools/Scripts/webkitpy/api_tests/runner.py
M Tools/Scripts/webkitpy/api_tests/runner_unittest.py
Log Message:
-----------
Add --exit-after-n-failures option to run-api-tests
https://bugs.webkit.org/show_bug.cgi?id=321046
rdar://176804299
Reviewed by Aakash Jain.
run-api-tests currently runs to completion, which lets API test EWS
steps run for hours when a change breaks many tests. Add
--exit-after-n-failures N so callers can bound the run. Enabling it on
EWS is a separate follow-up to Tools/CISupport/ews-build/steps.py.
Manager.run() catches EarlyExitException from report_result once the
failure count reaches the cap, then falls through to the normal
summary/JSON path so the "Ran N tests of M ..." line still reaches
stdout - filter-test-logs and buildbot's parseOutputLine observer both
depend on it.
* Tools/Scripts/run-api-tests:
(parse_args):
Add --exit-after-n-failures N option.
* Tools/Scripts/webkitpy/api_tests/runner.py:
(EarlyExitException):
(report_result):
(Runner.__init__):
Track a failure counter on the Runner. When report_result records a
FAILED/CRASHED/TIMEOUT status and the count reaches the cap, raise
EarlyExitException.
* Tools/Scripts/webkitpy/api_tests/manager.py:
(Manager.run):
Wire the option onto the Runner. Catch EarlyExitException and fall
through to the normal summary/JSON path.
* Tools/Scripts/webkitpy/api_tests/runner_unittest.py:
(ReportResultEarlyExitTest):
Cover report_result's early-exit behavior.
Canonical link: https://commits.webkit.org/319704@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications