Fix ExceptionListener for test env, remove broken CurrentDateDirectoryNamer, update schema

- ExceptionListener now only active in prod (skip dev AND test)
- Remove CurrentDateDirectoryNamer from vich_uploader config (class not available)
- Add test for test environment skip
- Update test DB schema for Event entity columns

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Serreau Jovann
2026-03-20 15:02:41 +01:00
parent dc870f9ea3
commit 9bd4201a61
3 changed files with 14 additions and 5 deletions

View File

@@ -25,6 +25,19 @@ class ExceptionListenerTest extends TestCase
self::assertNull($event->getResponse());
}
public function testDoesNothingInTestEnvironment(): void
{
$twig = $this->createMock(Environment::class);
$twig->expects(self::never())->method('render');
$listener = new ExceptionListener($twig, 'test');
$event = $this->createEvent(new \RuntimeException('test'));
$listener($event);
self::assertNull($event->getResponse());
}
public function testRenders404Template(): void
{
$twig = $this->createMock(Environment::class);