Same name in other branches
- 7.x-3.x tests/quicktabs.test \QuicktabsAdminTestCase::setUp()
Implementation of setUp().
Fichier
-
tests/
quicktabs.test, line 19
Classe
Code
function setUp() {
parent::setUp('ctools', 'quicktabs');
// Create and login user
$admin_user = $this->drupalCreateUser(array(
'access administration pages',
'administer quicktabs',
'administer nodes',
));
$this->drupalLogin($admin_user);
// Create some nodes that we can populate our tabs with.
for ($i = 0; $i < 5; $i++) {
$node = new stdClass();
$node->type = 'page';
$node->title = 'This is node number ' . ($i + 1);
$node->body[LANGUAGE_NONE][0]['value'] = $this->randomString(255);
node_object_prepare($node);
node_save($node);
}
}