Skip to content

Commit 9f0e18b

Browse files
committed
Use ::class keyword when possible
1 parent a50b4d8 commit 9f0e18b

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

Tests/Firewall/RememberMeListenerTest.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,14 @@
1313

1414
use PHPUnit\Framework\TestCase;
1515
use Symfony\Component\HttpFoundation\Request;
16+
use Symfony\Component\HttpFoundation\Session\SessionInterface;
1617
use Symfony\Component\HttpKernel\Event\RequestEvent;
1718
use Symfony\Component\HttpKernel\Event\ResponseEvent;
1819
use Symfony\Component\HttpKernel\HttpKernelInterface;
1920
use Symfony\Component\Security\Core\Exception\AuthenticationException;
2021
use Symfony\Component\Security\Http\Firewall\RememberMeListener;
2122
use Symfony\Component\Security\Http\SecurityEvents;
23+
use Symfony\Component\Security\Http\Session\SessionAuthenticationStrategyInterface;
2224
use Symfony\Contracts\EventDispatcher\EventDispatcherInterface;
2325

2426
class RememberMeListenerTest extends TestCase
@@ -227,7 +229,7 @@ public function testSessionStrategy()
227229
->willReturn($token)
228230
;
229231

230-
$session = $this->getMockBuilder('\Symfony\Component\HttpFoundation\Session\SessionInterface')->getMock();
232+
$session = $this->getMockBuilder(SessionInterface::class)->getMock();
231233
$session
232234
->expects($this->once())
233235
->method('isStarted')
@@ -277,7 +279,7 @@ public function testSessionIsMigratedByDefault()
277279
->willReturn($token)
278280
;
279281

280-
$session = $this->getMockBuilder('\Symfony\Component\HttpFoundation\Session\SessionInterface')->getMock();
282+
$session = $this->getMockBuilder(SessionInterface::class)->getMock();
281283
$session
282284
->expects($this->once())
283285
->method('isStarted')
@@ -402,6 +404,6 @@ protected function getDispatcher()
402404

403405
private function getSessionStrategy()
404406
{
405-
return $this->getMockBuilder('\Symfony\Component\Security\Http\Session\SessionAuthenticationStrategyInterface')->getMock();
407+
return $this->getMockBuilder(SessionAuthenticationStrategyInterface::class)->getMock();
406408
}
407409
}

0 commit comments

Comments
 (0)