Nette\Web\User Authorization test
isAuthenticated?
bool(FALSE)
getRoles()
array(1) {
0 => string(5) "guest"
}
is admin?
bool(FALSE)
is guest?
bool(TRUE)
authenticate as john
isAuthenticated?
bool(TRUE)
getRoles()
array(1) {
0 => string(5) "admin"
}
is admin?
bool(TRUE)
is guest?
bool(FALSE)
authorize without handler
InvalidStateException: Service 'Nette\Security\IAuthorizator' not found.
isAllowed('delete_file')?
bool(TRUE)
isAllowed('sleep_with_jany')?
bool(FALSE)
signing out...
isAllowed('delete_file')?
bool(FALSE)