-
-
Notifications
You must be signed in to change notification settings - Fork 336
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
[Core] Fix undefined array key 0 on FormatPerservingPrinter #1619
Conversation
d9ccf41
to
7c60037
Compare
Checking current stmts seems remove use statement: 1) Rector\Core\Tests\Issues\PrintStmtsIndex\PrintStmtsIndexTest::test with data set #0 (Symplify\SmartFileSystem\SmartFileInfo Object (...))
tests/Issues/PrintStmtsIndex/Fixture/fixture.php.inc
Failed asserting that string matches format description.
--- Expected
+++ Actual
@@ @@
<?php
-use Illuminate\Http\Request;
- which should not. |
Fixed 🎉 |
The configured config : $services->set(RenameClassRector::class)
->configure([
'Request' => 'Illuminate\Http\Request',
]); applied succesfully, but it still removes the use statement, which should not. |
The code originally had unused use Illuminate\Http\Request; and it was removed during the |
I added fixtures for auto import enabled d6b6266 seems will make issue : 1) Rector\Core\Tests\Issues\PrintStmtsIndexAutoImport\PrintStmtsIndexAutoImportTest::test with data set #0 (Symplify\SmartFileSystem\SmartFileInfo Object (...))
tests/Issues/PrintStmtsIndexAutoImport/Fixture/fixture_request_call.php.inc
Failed asserting that string matches format description.
--- Expected
+++ Actual
@@ @@
<?php
use Illuminate\Support\Facades\Route;
-use Illuminate\Http\Request; |
rolling back |
Fixed 🎉 with ensure use name has |
All checks have passed 🎉 @TomasVotruba it is ready for review. |
Thank you, let's ship it |
Fixes rectorphp/rector#6907 Closes #1618