Require Flow 9 and PHP 8.3, upgrade to PHPUnit 12 - #74
Merged
Merged
Conversation
The package now requires Flow 9 and PHP 8.3 or later. It is tested with PHPUnit 12 on PHP 8.3, 8.4 and 8.5. lcobucci/jwt is raised to version 5, which supports PHP 8.5. Previously, the package supported Flow 7.3 and PHP 8.1. Keeping these versions would have pinned lcobucci/jwt to the outdated 4.x line and PHPUnit to version 10 at most. Flow 9.2 itself requires PHP 8.4, so current Flow applications are not affected. Still, this is a breaking change and needs a new major release. The tests use attributes and test stubs, as PHPUnit 12 expects. They now fail on deprecations, so PHP 8.5 issues show up in CI. One test built an authentication token without a provider name and triggered such a deprecation. Flow always sets that name, so the test was corrected instead of the middleware.
Dependency injection, configuration injection and the signal of the authentication provider are declared with PHP attributes. The discovery response is decoded with the native json_decode(), because the Guzzle helper function is deprecated.
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.
This prepares the package for current Flow and PHP versions. It now requires Flow 9 and PHP 8.3 or later, raises lcobucci/jwt to version 5 and runs the tests with PHPUnit 12 on PHP 8.3, 8.4 and 8.5. Flow 9.2 is covered by the
^9.0constraint.Dropping Flow 7.3/8 and PHP 8.1/8.2 is a breaking change, so this needs a new major release.
Also, the classes use PHP attributes instead of doc comment annotations, and the deprecated Guzzle
json_decode()helper is replaced by the native function.