@@ -83,19 +83,7 @@ public function testExpressionLanguageNotInstalled(): void
83
83
$ checker ->isGranted (Dummy::class, 'is_granted("ROLE_ADMIN") ' );
84
84
}
85
85
86
- public function testNotBehindAFirewall (): void
87
- {
88
- $ this ->expectException (\LogicException::class);
89
- $ this ->expectExceptionMessage ('The current token must be set to use the "security" attribute (is the URL behind a firewall?). ' );
90
-
91
- $ authenticationTrustResolverProphecy = $ this ->prophesize (AuthenticationTrustResolverInterface::class);
92
- $ tokenStorageProphecy = $ this ->prophesize (TokenStorageInterface::class);
93
-
94
- $ checker = new ResourceAccessChecker (null , $ authenticationTrustResolverProphecy ->reveal (), null , $ tokenStorageProphecy ->reveal ());
95
- $ checker ->isGranted (Dummy::class, 'is_granted("ROLE_ADMIN") ' );
96
- }
97
-
98
- public function testWithoutAuthenticationTokenAndExceptionOnNoTokenIsFalse (): void
86
+ public function testWithoutAuthenticationToken (): void
99
87
{
100
88
$ expressionLanguageProphecy = $ this ->prophesize (ExpressionLanguage::class);
101
89
$ expressionLanguageProphecy ->evaluate ('is_granted("ROLE_ADMIN") ' , Argument::type ('array ' ))->willReturn (true )->shouldBeCalled ();
@@ -106,7 +94,7 @@ public function testWithoutAuthenticationTokenAndExceptionOnNoTokenIsFalse(): vo
106
94
107
95
$ tokenStorageProphecy ->getToken ()->willReturn (null );
108
96
109
- $ checker = new ResourceAccessChecker ($ expressionLanguageProphecy ->reveal (), $ authenticationTrustResolverProphecy ->reveal (), null , $ tokenStorageProphecy ->reveal (), $ authorizationCheckerProphecy ->reveal (), false );
97
+ $ checker = new ResourceAccessChecker ($ expressionLanguageProphecy ->reveal (), $ authenticationTrustResolverProphecy ->reveal (), null , $ tokenStorageProphecy ->reveal (), $ authorizationCheckerProphecy ->reveal ());
110
98
self ::assertTrue ($ checker ->isGranted (Dummy::class, 'is_granted("ROLE_ADMIN") ' ));
111
99
}
112
100
}
0 commit comments