-
-
Notifications
You must be signed in to change notification settings - Fork 424
[Alternative] Add EnumCaseToPascalCaseRector with use of DynamicSourceLocatorProvider #6899
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@marcelthole @TomasVotruba All checks have passed 🎉 🎉 🎉 I think it is ready ;) |
22495d0 to
10ce326
Compare
|
Rebased and cleaned up use of |
10ce326 to
97995f7
Compare
|
Rebased and cleaned up unnecessary manual reset as already in |
d0be12d to
26bda34
Compare
|
Rebased 👍 |
26bda34 to
80a0d0b
Compare
|
@marcelthole @boesing I added failing new test for use of 80a0d0b#diff-9c0f8fca70b157b9f8b24c57101088a00f86f370940d68c4d595544d5dee22ff as |
cd5cc16 to
9ac254c
Compare
|
Fixed with verify that target path is part of autoload paths as fallback 9ac254c |
|
@marcelthole @boesing I talked with @TomasVotruba today, and it is ok to merge it as is :) This rule is not part of any set, so after the merge, you can try dev-main: and register manually: <?php
declare(strict_types=1);
use Rector\CodingStyle\Rector\Enum_\EnumCaseToPascalCaseRector;
use Rector\Config\RectorConfig;
return RectorConfig::configure()
// other config here...
->withRules([EnumCaseToPascalCaseRector::class]); |
|
This pull request has been automatically locked because it has been closed for 150 days. Please open a new PR if you want to continue the work. |
@marcelthole here I cherry-picked your commits from PR:
as an alternative PR, this utilize
DynamicSourceLocatorProviderwhich verify target is on theReflectorwhich use of paths defined in configuration.The
StatusEnumneeds to be moved toSourceso it marked as "outside" Fixture so be skipped from change.This on unit test, I add
includeFixtureDirectoryAsSourceflag so defined PHP classes inFixturedirectory can be load when set.Closes #6890