Repository navigation
test: let the dynamic-element tests pass on WebKit - #485
Merged
Merged
Conversation
JuroOravec
added a commit
that referenced
this pull request
Oct 28, 2026
WebKit does not treat a response with no Content-Type as HTML, so eight routes in test_vue_dynamic_element_e2e.py that served their page body without a type failed on WebKit only. A helper now serves the shared host page with content_type="text/html", and the one multi-line page route declares it too. Co-Authored-By: Claude Opus 5.5 <[email protected]>
In WebKit, Playwright answers a repeated request for a routed URL from the first response without calling the route again, even when that response says no-store. The extension script loader test counted route calls to prove each retry makes a new request, so it failed on WebKit only. A WebKit run against a real server shows each retry does reach the server, so the count is now checked in Chromium and Firefox, where the route sees every request. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ee it The fragment manager test aborts the routed request for a late script, then loads the fragment again and waits for a second request. In WebKit, Playwright fails that second load at once without calling the route, so the test timed out on WebKit only. A WebKit run against a real server shows the retry does reach the server. The late-script check now lives in its own helper, which the test runs in Chromium and Firefox. Co-Authored-By: Claude Opus 5.5 <[email protected]>
JuroOravec
force-pushed
the
fix/webkit-route-content-type
branch
from
October 28, 2026 11:34
6ba96f7 to
8dc290a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Eight tests in
packages/py/citry/tests/e2e/test_vue_dynamic_element_e2e.pyfail on WebKit only. This PR fixes both causes. It is a test-only change.Pages served with no content type
These tests serve their page through a Playwright route that sets no content type. Chromium and Firefox treat such a body as HTML. WebKit does not, so the page never gets its
<div id="host">.The tests now declare
content_type="text/html". Seven of them served the same host page, so a small helper,_serve_host_page, now serves it. The eighth test serves a longer page, so it sets the type inline.Script retries that the route does not see
test_extension_script_loader_retries_and_restarts_same_app_idcounts calls to its routes to prove that each retry makes a new request. In WebKit, the route was called only once per URL, even when a debug run added ano-storeheader to the response. A probe against a real HTTP server shows that WebKit does send each retry to the server, as Chromium and Firefox do, so Playwright's routing is the likely cause. So the count is now checked only in Chromium and Firefox, where the route sees every request. The test's other checks run in every browser.Evidence
debug/webkit-e2ebranch:test_extension_script_loader_retries_and_restarts_same_app_idstill fails on its request count;no-store;route.fulfillin the repository's e2e tests. Every route that serves HTML, JS, CSS or JSON either declares its type or, in one benchmark test, copies the headers of the real response it forwards. The few routes without a type are error or empty responses, where only the status matters.test_vue_dynamic_element_e2e.pypasses on Chromium and Firefox. ruff and ruff format pass. WebKit hangs on my machine, so it ran only in CI.test_fragment_manager_loads_and_mounts_python_composed_componentalso fails on WebKit because of Playwright's routing: after the test aborts the routed request for a script, WebKit fails the next load of that URL at once, without calling the route. test: make four e2e checks pass on Firefox #460 changes that test too, so its fix will follow once test: make four e2e checks pass on Firefox #460 merges.🤖 Generated with Claude Code