diff --git a/backend/tests/Unit/Auth/UseCases/CreateSessionTest.php b/backend/tests/Unit/Auth/UseCases/CreateSessionTest.php index d6368f2..0367f1c 100644 --- a/backend/tests/Unit/Auth/UseCases/CreateSessionTest.php +++ b/backend/tests/Unit/Auth/UseCases/CreateSessionTest.php @@ -6,10 +6,11 @@ use App\Auth\Clock; use App\Auth\UseCases\CreateSession\CreateSession; use App\Shared\ValueObject\EmailAddress; use App\User\User; -use PHPUnit\Framework\TestCase; +use DateTimeImmutable; use Tests\Fakes\FakeClock; use Tests\Fakes\FakeSessionRepository; use Tests\Fakes\FakeTokenGenerator; +use Tests\TestCase; class CreateSessionTest extends TestCase { @@ -22,9 +23,15 @@ class CreateSessionTest extends TestCase { $this->sessionRepo = new FakeSessionRepository(); $this->tokenGenerator = new FakeTokenGenerator(); - $this->clock = new FakeClock(); + $this->clock = new FakeClock( + new DateTimeImmutable('2026-05-18 12:00:00') + ); - $this->createSession = new CreateSession($this->sessionRepo, $this->tokenGenerator, $this->clock); + $this->createSession = new CreateSession( + $this->sessionRepo, + $this->tokenGenerator, + $this->clock + ); } public function testCreatesSessionForUser(): void