@@ -20,18 +20,18 @@ $users = [
2020
2121$ authenticator = new SimpleAuthenticator ($ users );
2222
23- $ identity = $ authenticator ->authenticate ([ 'john ' , 'password123! ' ] );
23+ $ identity = $ authenticator ->authenticate ('john ' , 'password123! ' );
2424Assert::type (Nette \Security \IIdentity::class, $ identity );
2525Assert::equal ('john ' , $ identity ->getId ());
2626
27- $ identity = $ authenticator ->authenticate ([ 'admin ' , 'admin ' ] );
27+ $ identity = $ authenticator ->authenticate ('admin ' , 'admin ' );
2828Assert::type (Nette \Security \IIdentity::class, $ identity );
2929Assert::equal ('admin ' , $ identity ->getId ());
3030
3131Assert::exception (function () use ($ authenticator ) {
32- $ authenticator ->authenticate ([ 'admin ' , 'wrong password ' ] );
32+ $ authenticator ->authenticate ('admin ' , 'wrong password ' );
3333}, Nette \Security \AuthenticationException::class, 'Invalid password. ' );
3434
3535Assert::exception (function () use ($ authenticator ) {
36- $ authenticator ->authenticate ([ 'nobody ' , 'password ' ] );
36+ $ authenticator ->authenticate ('nobody ' , 'password ' );
3737}, Nette \Security \AuthenticationException::class, "User 'nobody' not found. " );
0 commit comments