Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 33bb8468a9c3e01eadf816004eed293967a6feae
https://github.com/WebKit/WebKit/commit/33bb8468a9c3e01eadf816004eed293967a6feae
Author: Simon Fraser <[email protected]>
Date: 2026-04-17 (Fri, 17 Apr 2026)
Changed paths:
M LayoutTests/fast/harness/full_results.json
M LayoutTests/fast/harness/results-expected.txt
M LayoutTests/fast/harness/results.html
M Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py
M Tools/Scripts/webkitpy/layout_tests/controllers/single_test_runner.py
M Tools/Scripts/webkitpy/layout_tests/controllers/test_result_writer.py
M
Tools/Scripts/webkitpy/layout_tests/controllers/test_result_writer_unittest.py
M Tools/Scripts/webkitpy/layout_tests/models/test_failures.py
M Tools/Scripts/webkitpy/layout_tests/models/test_run_results.py
M Tools/Scripts/webkitpy/port/base.py
Log Message:
-----------
[WPT] reftest variants not obeyed
https://bugs.webkit.org/show_bug.cgi?id=278243
rdar://134073271
Reviewed by Alan Baradlay.
WPT supports tests with variants; these are declared in a meta tags, and cause
the test
to be run with URL params, which may contain special characters including
slashes.
This requires that various bits of test infrastructure handle test names
containing
slashes.
Add static methods to `Port` to separate a test name into the base name and
variant part, and use that throughout the webkitpy code. Also add a helper
to sanitize the variant part for when we produce pathnames.
results.html also needs updating to handle variant pathnames.
This was tested manually by importing
`css/css-backgrounds/box-shadow-radius-generated.html`
which includes variants with slashes. I verified that variant lines in
`TestExpectations`
worked.
Unit tests are lacking; in particular, `layout_test_finder.py` needs much more.
* LayoutTests/fast/harness/full_results.json:
* LayoutTests/fast/harness/results-expected.txt:
* LayoutTests/fast/harness/results.html:
* Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py:
(LayoutTestFinder):
(LayoutTestFinder._expectations_for_test): The expectation for a variant test
needs
to find the base filename; the expected test is then run with the same URL
params
as the test.
* Tools/Scripts/webkitpy/layout_tests/controllers/single_test_runner.py:
(SingleTestRunner._fuzzy_tolerance_for_reference): Need to find the base
filename to look
for tolerance values.
* Tools/Scripts/webkitpy/layout_tests/controllers/test_result_writer.py:
(TestResultWriter._modified_filename): Use the helper function. It has a
slightly
different behavior where the separator is included in the variant part, so strip
that off via `[1:]`.
(TestResultWriter._output_testname):
*
Tools/Scripts/webkitpy/layout_tests/controllers/test_result_writer_unittest.py:
(TestResultWriterTest.test_output_testname):
* Tools/Scripts/webkitpy/layout_tests/models/test_failures.py:
(FailureReftestMismatch.write_failure):
* Tools/Scripts/webkitpy/layout_tests/models/test_run_results.py:
(summarize_results): Need to look for the `/` in the basename, since it might
appear
in the variant part.
* Tools/Scripts/webkitpy/port/base.py:
(Port):
(Port.test_name_and_variant):
(Port.sanitized_variant):
(Port._expected_baselines_for_suffixes):
Canonical link: https://commits.webkit.org/311511@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications