forked from silverstripe/silverstripe-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/3.0' into 3.1
- Loading branch information
Showing
8 changed files
with
91 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -299,7 +299,7 @@ public function testRepeatedLoginAttemptsLockingPeopleOut() { | |
$member->LockedOutUntil, | ||
'User does not have a lockout time set if under threshold for failed attempts' | ||
); | ||
$this->assertContains($this->loginErrorMessage(), _t('Member.ERRORWRONGCRED')); | ||
$this->assertContains($this->loginErrorMessage(), Convert::raw2xml(_t('Member.ERRORWRONGCRED'))); | ||
} else { | ||
// Fuzzy matching for time to avoid side effects from slow running tests | ||
$this->assertGreaterThan( | ||
|
@@ -337,7 +337,7 @@ public function testRepeatedLoginAttemptsLockingPeopleOut() { | |
$member->ID, | ||
'After lockout expires, the user can login again' | ||
); | ||
|
||
// Log the user out | ||
$this->session()->inst_set('loggedInAs', null); | ||
|
||
|
@@ -346,11 +346,12 @@ public function testRepeatedLoginAttemptsLockingPeopleOut() { | |
$this->doTestLoginForm('[email protected]' , 'incorrectpassword'); | ||
} | ||
$this->assertNull($this->session()->inst_get('loggedInAs')); | ||
$this->assertTrue( | ||
false !== stripos($this->loginErrorMessage(), _t('Member.ERRORWRONGCRED')), | ||
$this->assertContains( | ||
$this->loginErrorMessage(), | ||
Convert::raw2xml(_t('Member.ERRORWRONGCRED')), | ||
'The user can retry with a wrong password after the lockout expires' | ||
); | ||
|
||
$this->doTestLoginForm('[email protected]' , '1nitialPassword'); | ||
$this->assertEquals( | ||
$this->session()->inst_get('loggedInAs'), | ||
|