Trim remember me delegation tests
This commit is contained in:
@@ -406,28 +406,6 @@ class RememberMeServiceTest extends TestCase
|
||||
// forgetAllForUser
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
public function testForgetAllForUserDelegatesToRepository(): void
|
||||
{
|
||||
$tokenRepo = $this->createMock(RememberTokenRepositoryInterface::class);
|
||||
$tokenRepo->expects($this->once())->method('deleteByUserId')->with(42);
|
||||
|
||||
$service = $this->newService(tokenRepository: $tokenRepo);
|
||||
$service->forgetAllForUser(42);
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------
|
||||
// expireAllTokensByAdmin
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
public function testExpireAllTokensByAdminDelegatesToRepository(): void
|
||||
{
|
||||
$tokenRepo = $this->createMock(RememberTokenRepositoryInterface::class);
|
||||
$tokenRepo->expects($this->once())->method('expireAllByAdmin')->willReturn(15);
|
||||
|
||||
$service = $this->newService(tokenRepository: $tokenRepo);
|
||||
$this->assertSame(15, $service->expireAllTokensByAdmin());
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------
|
||||
// Dynamic TTL via AuthSettingsGateway
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user