20 lines
492 B
PHP
20 lines
492 B
PHP
<?php
|
|
declare(strict_types=1);
|
|
|
|
namespace Tests\Shared;
|
|
|
|
use App\Shared\Exception\NotFoundException;
|
|
use PHPUnit\Framework\TestCase;
|
|
|
|
#[\PHPUnit\Framework\Attributes\AllowMockObjectsWithoutExpectations]
|
|
|
|
final class NotFoundExceptionTest extends TestCase
|
|
{
|
|
public function testMessageContainsEntityAndIdentifier(): void
|
|
{
|
|
$exception = new NotFoundException('Article', 'mon-slug');
|
|
|
|
self::assertSame('Article introuvable : mon-slug', $exception->getMessage());
|
|
}
|
|
}
|