protected function PropertiesBaseTestCase::loginAdmin in Dynamic properties 7
Log in with administrative permissions.
Admin user is created on-demand.
4 calls to PropertiesBaseTestCase::loginAdmin()
- PropertiesAdministrationTestCase::testCreating in ./
properties.test - PropertiesAdministrationTestCase::testEditCategory in ./
properties.test - Tests for creating and editing a category.
- PropertiesTestCase::testAutocomplete in ./
properties.test - Test autocomplete functionality.
- PropertiesTestCase::testPropertyFieldCreation in ./
properties.test - Test field creation functionality.
2 methods override PropertiesBaseTestCase::loginAdmin()
- PropertiesCompareTestCase::loginAdmin in properties_compare/
properties_compare.test - Log in with administrative permissions.
- PropertiesTemplateBaseTestCase::loginAdmin in properties_template/
properties_template.test - Log in with administrative permissions.
File
- ./
properties.test, line 161 - Contains tests for the properties.module
Class
- PropertiesBaseTestCase
- Base class for properties tests, provides helper methods.
Code
protected function loginAdmin() {
if (empty($this->admin)) {
$this->admin = $this
->drupalCreateUser(array(
'administer nodes',
'administer content types',
'create page content',
'edit any page content',
'administer properties attributes',
'administer properties categories',
'add properties attributes',
'add properties categories',
));
}
$this
->drupalLogin($this->admin);
}