mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merged revisions 52617 via svnmerge from
http://svn.silverstripe.com/open/modules/sapphire/branches/govtsecurity ........ r52617 | sminnee | 2008-04-13 16:57:53 +1200 (Sun, 13 Apr 2008) | 1 line Updated changed password test to check for a sent email ........ git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@53469 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
f82b03c74d
commit
efd1cf63e2
@ -35,6 +35,18 @@ class MemberTest extends SapphireTest {
|
||||
$this->assertTrue($record->checkPassword('1nitialPassword'), "Password 1nitialPassword not found in MemberRecord");
|
||||
}
|
||||
|
||||
/**
|
||||
* Test that changed passwords will send an email
|
||||
*/
|
||||
function testChangedPasswordEmaling() {
|
||||
$this->clearEmails();
|
||||
|
||||
$member = $this->objFromFixture('Member', 'test');
|
||||
$valid = $member->changePassword('32asDF##$$%%');
|
||||
$this->assertTrue($valid->valid());
|
||||
$this->assertEmailSent("sam@silverstripe.com", null, "/changed password/", '/sam@silverstripe\.com.*32asDF##\$\$%%/');
|
||||
}
|
||||
|
||||
/**
|
||||
* Test that passwords validate against NZ e-government guidelines
|
||||
* - don't allow the use of the last 6 passwords
|
||||
|
Loading…
Reference in New Issue
Block a user