Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
configureLogoutUrlGenerator example
->
expects
(
$this
->
once
(
)
)
->
method
(
'getFirewallConfig'
)
->
with
(
$request
)
->
willReturn
(
null
)
;
$firewallMap
->
expects
(
$this
->
once
(
)
)
->
method
(
'getListeners'
)
->
with
(
$request
)
->
willReturn
(
[
[
$listener
]
, null, null
]
)
;
$firewall
=
new
TraceableFirewallListener
(
$firewallMap
,
new
EventDispatcher
(
)
,
new
LogoutUrlGenerator
(
)
)
;
$firewall
->
configureLogoutUrlGenerator
(
$event
)
;
$firewall
->
onKernelRequest
(
$event
)
;
$listeners
=
$firewall
->
getWrappedListeners
(
)
;
$this
->
assertCount
(
1,
$listeners
)
;
$this
->
assertSame
(
$listener
,
$listeners
[
0
]
[
'stub'
]
)
;
}
public
function
testOnKernelRequestRecordsAuthenticatorsInfo
(
)
{
$request
=
new
Request
(
)
;