ci(rector): run the refactoring check on every build - #3
Merged
Conversation
Rector was added with the dev dependencies but left out of both the aggregate test script and the workflow, because it could not be verified at the time. It now passes clean on Laravel 12 and 13, so it joins the chain after the formatting check and gets its own step. The step skips Windows, matching type coverage and the test suite. The check describes code shape rather than runtime behaviour, so the eight Linux rows already cover both supported Laravel versions and both PHP versions. Claude-Session: https://claude.ai/code/session_0131mg78D5c5ao3zWZ5c8sDX
rector.php skips three rules by class name, and Rector fails hard when
a skipped rule does not exist. On a prefer-lowest build the previous
constraints resolved rector 2.0.0 and rector-laravel 2.0.0, where none
of the three had been written yet:
[ERROR] These rules from "$rectorConfig->skip()" does not exist
* RectorLaravel\Rector\FuncCall\AppToResolveRector
* RectorLaravel\Rector\ClassMethod\MakeModelAttributesAndScopesProtectedRector
* Rector\Php84\Rector\MethodCall\NewMethodCallWithoutParenthesesRector
Both constraints move to ^2.6, the range that carries them. Verified
on the two ends of the matrix: Laravel 12 with prefer-lowest, which
resolves rector 2.6.4 and rector-laravel 2.6.1, and Laravel 13 with
prefer-stable. Both dependencies are dev only, so nothing changes for
an application installing the package.
Claude-Session: https://claude.ai/code/session_0131mg78D5c5ao3zWZ5c8sDX
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.
No description provided.