function JammerPreviewButtonTest::testUserDelete in Jammer 6
File
- ./
jammer.test, line 56 - Jammer simpletest test suite.
Class
- JammerPreviewButtonTest
- @file
Code
function testUserDelete() {
$user = $this
->drupalCreateUser(array(
'access user profiles',
'administer users',
));
$user2 = $this
->drupalCreateUser();
$this
->drupalLogin($user);
variable_set('jammer_user_delete_hide_button', 0);
$this
->drupalGet("user/{$user2->uid}/edit");
$this
->assertRaw('id="edit-delete"', 'delete button visible');
variable_set('jammer_user_delete_hide_button', 1);
$this
->drupalGet("user/{$user2->uid}/edit");
$this
->assertNoRaw('id="edit-delete"', 'delete button hidden');
}