Add test coverage for remaining controllers, fix label accessibility, refactor duplicated code
New tests (47 added, 622 total): - MonitorMessengerCommand: no failures, failures with email, null error, multiple (4) - UnsubscribeController: unsubscribe with invitations refused + admin notified (1) - AdminController: suspend/reactivate orga, orders page with filters, logs, invite orga submit/empty, delete/resend invitation, export CSV/PDF (13) - AccountController: export CSV/PDF, getAllowedBilletTypes (free/basic/sur-mesure/null), billet type restriction, finance stats all statuses, soldCounts (9) - HomeController: city filter, date filter, all filters combined, stock route (4) - OrderController: event ended, invalid cart JSON, invalid email, stock zero (4) - MailerService: getAdminEmail, getAdminFrom (2) - JS: comment node, tabs missing panel/id/parent, cart stock polling edge cases (10) Accessibility fixes: - events.html.twig: add for/id on search, city, date labels - admin/orders.html.twig: add for/id on search, status labels Code quality: - cart.js: remove dead ternaire branch (max > 10 always plural) - tabs.js: use optional chaining for tablist?.setAttribute - MeilisearchConsistencyCommand: extract diffAndReport() (was duplicated 3x) - Email templates: extract _order_items_table.html.twig partial - SonarQube: exclude src/Entity/** from CPD Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -53,6 +53,18 @@ class MailerServiceTest extends TestCase
|
||||
);
|
||||
}
|
||||
|
||||
public function testGetAdminEmail(): void
|
||||
{
|
||||
$service = $this->createService();
|
||||
self::assertSame('contact@test.com', $service->getAdminEmail());
|
||||
}
|
||||
|
||||
public function testGetAdminFrom(): void
|
||||
{
|
||||
$service = $this->createService();
|
||||
self::assertSame('E-Ticket <contact@test.com>', $service->getAdminFrom());
|
||||
}
|
||||
|
||||
public function testSendEmailSkipsUnsubscribedRecipient(): void
|
||||
{
|
||||
$this->unsubscribeManager->method('isUnsubscribed')->willReturn(true);
|
||||
|
||||
Reference in New Issue
Block a user