This repository was archived by the owner on Jul 24, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 19
19
|
20
20
*/
21
21
22
- 'username_attribute ' => ['email ' => 'mail ' ],
22
+ 'username_attribute ' => ['username ' => 'samaccountname ' ],
23
23
24
24
/*
25
25
|--------------------------------------------------------------------------
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ public function testAuthPasses()
59
59
Adldap::shouldReceive ('users ' )->once ()->andReturn ($ mockedUsers );
60
60
Adldap::shouldReceive ('authenticate ' )->once ()->andReturn (true );
61
61
62
- $ this ->assertTrue (Auth::attempt (['email ' => 'jdoe@email.com ' , 'password ' => '12345 ' ]));
62
+ $ this ->assertTrue (Auth::attempt (['username ' => 'jdoe ' , 'password ' => '12345 ' ]));
63
63
64
64
$ user = Auth::user ();
65
65
@@ -100,7 +100,7 @@ public function testAuthFails()
100
100
101
101
Adldap::shouldReceive ('users ' )->once ()->andReturn ($ mockedUsers );
102
102
103
- $ this ->assertFalse (Auth::attempt (['email ' => 'jdoe@email.com ' , 'password ' => '12345 ' ]));
103
+ $ this ->assertFalse (Auth::attempt (['username ' => 'jdoe ' , 'password ' => '12345 ' ]));
104
104
}
105
105
106
106
public function testAuthFailsWhenUserFound ()
@@ -127,7 +127,7 @@ public function testAuthFailsWhenUserFound()
127
127
Adldap::shouldReceive ('users ' )->once ()->andReturn ($ mockedUsers );
128
128
Adldap::shouldReceive ('authenticate ' )->once ()->andReturn (false );
129
129
130
- $ this ->assertFalse (Auth::attempt (['email ' => 'jdoe@email.com ' , 'password ' => '12345 ' ]));
130
+ $ this ->assertFalse (Auth::attempt (['username ' => 'jdoe ' , 'password ' => '12345 ' ]));
131
131
}
132
132
133
133
public function testCredentialsKeyDoesNotExist ()
You can’t perform that action at this time.
0 commit comments