test: support phpunit 11, 12 and 13, and run the suite with paratest - #205
Merged
Conversation
Test metadata is duplicated as attributes: 9.6 only reads the annotations, 13 only reads the attributes.
The bootstrap wiped var/ in every worker, so workers cleared each others cache and artifacts mid-run: only the parent cleans up now. A test was also renamed, since paratest filters each chunk with /name$/ and a name ending with another test name in the same class runs twice.
Committed by accident in zenstruck#121 alongside the fixture it duplicates: only `tests/Fixture/files/attachment.zip` is read, by the `/zip` route.
The extension was never registered here, so nothing exercised it. The new tests drive the hooks phpunit calls, because saveBrowserStates() swallows every Throwable and a broken save would otherwise go unnoticed.
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.
Widens the PHPUnit constraint to 11, 12 and 13 by carrying test metadata in both forms: 9.6 reads only the annotations, 13 reads only the attributes.
That unlocks ParaTest, which the CI test job now uses (
--functional). Two things were needed: the bootstrap wipedvar/in every worker, so workers cleared each other's cache and artifacts mid-run, and one test had to be renamed because ParaTest filters chunks with/name$/.Also registers
BrowserExtensioninphpunit.xml.dist, which was never enabled here, and covers its artifact saving:saveBrowserStates()swallows everyThrowable, so a broken save went unnoticed.