Some random tests and fixes (#6000)

* added tests for form models
* apply form theme only to the own custom form type
* change route order for improves matching
This commit is contained in:
Kevin Papst
2026-06-17 10:20:50 +02:00
committed by GitHub
parent f8bc853d2f
commit 8bf711c417
11 changed files with 403 additions and 32 deletions

View File

@@ -1,3 +1,28 @@
home:
path: /
defaults:
_controller: Symfony\Bundle\FrameworkBundle\Controller\RedirectController::redirectAction
route: homepage
permanent: true
# SF DefaultAuthenticationSuccessHandler uses /login as default target
loginFallback:
path: /login
defaults:
_controller: Symfony\Bundle\FrameworkBundle\Controller\RedirectController::redirectAction
_locale: '%locale%'
route: login
permanent: true
# SF LogoutListener uses /logout as default target
logoutFallback:
path: /logout
defaults:
_controller: Symfony\Bundle\FrameworkBundle\Controller\RedirectController::redirectAction
_locale: '%locale%'
route: logout
permanent: true
controllers:
resource: ../src/Controller/
type: attribute
@@ -31,13 +56,6 @@ kernel:
resource: ../src/Kernel.php
type: attribute
home:
path: /
defaults:
_controller: Symfony\Bundle\FrameworkBundle\Controller\RedirectController::redirectAction
route: homepage
permanent: true
homeLocale:
path: /{_locale}
defaults:
@@ -46,24 +64,6 @@ homeLocale:
route: homepage
permanent: true
# SF DefaultAuthenticationSuccessHandler uses /login as default target
loginFallback:
path: /login
defaults:
_controller: Symfony\Bundle\FrameworkBundle\Controller\RedirectController::redirectAction
_locale: '%locale%'
route: login
permanent: true
# SF LogoutListener uses /logout as default target
logoutFallback:
path: /logout
defaults:
_controller: Symfony\Bundle\FrameworkBundle\Controller\RedirectController::redirectAction
_locale: '%locale%'
route: logout
permanent: true
2fa_login:
path: /{_locale}/auth/2fa
defaults: