public function SecureSiteFunctionUserSaveUnitTest::testSecureSiteFunctionUserSaveUpdatePassUnchanged in Secure Site 7.2
Same name and namespace in other branches
- 6.2 securesite.test \SecureSiteFunctionUserSaveUnitTest::testSecureSiteFunctionUserSaveUpdatePassUnchanged()
Update user name without changing password.
File
- ./
securesite.test, line 419 - Tests for Secure Site module.
Class
- SecureSiteFunctionUserSaveUnitTest
- Unit tests for user_save().
Code
public function testSecureSiteFunctionUserSaveUpdatePassUnchanged() {
$user = user_save($this->user, array(
'name' => $this
->randomName(),
));
$command = "{$this->stored_passwords} username=" . escapeshellarg($user->name) . " {$this->pass_arg} {$this->realm_arg}";
$this
->assertTrue(exec($command) == "{$user->name} not found in {$this->realm}.", t('Updating user name without changing password.'));
}