diff --git a/tests/Maker/Security/MakeFormLoginTest.php b/tests/Maker/Security/MakeFormLoginTest.php index 4e1c90c21..a3c3bf4a7 100644 --- a/tests/Maker/Security/MakeFormLoginTest.php +++ b/tests/Maker/Security/MakeFormLoginTest.php @@ -103,6 +103,11 @@ public function getTestDetails(): \Generator private function runLoginTest(MakerTestRunner $runner): void { + if (60000 > $runner->getSymfonyVersion()) { + // @legacy - In 5.4 tests, we need to tell Symfony to look for the route attributes in `src/Controller` + $runner->copy('router-annotations.yaml', 'config/routes/annotations.yaml'); + } + $fixturePath = 'security/make-form-login/'; $runner->renderTemplateFile($fixturePath.'/LoginTest.php', 'tests/LoginTest.php', []);