Register the kernel route before any test route - #59
Draft
Mir-Zairan wants to merge 3 commits into
Draft
Mir-Zairan wants to merge 3 commits into
Mir-Zairan wants to merge 3 commits into
Conversation
The kernel route was added on the first visit, so a route a test added before it never ran, and requests to other hosts went to the network past context routes. It is now the oldest page route and passes those on with fallback().
…t visit The changelog now says test routes run before the kernel route and must fall back to reach it, and the architecture docs explain the route order. The debug log for external requests names the call it makes.
Temporary: CI needs playwright-php/playwright#182 to run the new route tests. Drop this commit and raise the constraint once that fix is released.
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.
Draft until the fix in playwright-php/playwright#182 is released. That PR makes the newest route answer alone, and
fallback()pass the request to the next one.Under that change, the kernel route hides test routes added before the first visit, because it is registered lazily on that visit. It also sends outside hosts straight to the network with
continue(). This registers the kernel route when the client is created, so test routes always run first and canfallback()to it. Outside hosts now go throughfallback(), so older routes still see them.Behaviour change: a test route must call
fallback(), notcontinue(), to reach the kernel. The CHANGELOG says so.The last commit points CI at the #182 branch. It gets dropped, and the constraint raised, once that release is out.