Skip to content
This repository was archived by the owner on May 31, 2024. It is now read-only.

Commit 9aa9f48

Browse files
Merge branch '2.6' into 2.7
* 2.6: [2.6] Static Code Analysis for Components [Security/Http] Fix test relying on a private property
2 parents 3570d0f + 79b1d65 commit 9aa9f48

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

Http/Tests/Firewall/AnonymousAuthenticationListenerTest.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,9 @@ public function testHandleWithTokenStorageHavingNoToken()
5454
$authenticationManager
5555
->expects($this->once())
5656
->method('authenticate')
57-
->with(self::logicalAnd(
58-
$this->isInstanceOf('Symfony\Component\Security\Core\Authentication\Token\AnonymousToken'),
59-
$this->attributeEqualTo('key', 'TheKey')
60-
))
57+
->with($this->callback(function ($token) {
58+
return 'TheKey' === $token->getKey();
59+
}))
6160
->will($this->returnValue($anonymousToken))
6261
;
6362

0 commit comments

Comments
 (0)