public function RecipeWebTestBase::setUp in Recipe 7.2
Same name and namespace in other branches
- 7 src/Tests/RecipeWebTestBase.php \Drupal\recipe\Tests\RecipeWebTestBase::setUp()
1 call to RecipeWebTestBase::setUp()
- IngredientSettingsTest::setUp in src/
Tests/ IngredientSettingsTest.php
1 method overrides RecipeWebTestBase::setUp()
- IngredientSettingsTest::setUp in src/
Tests/ IngredientSettingsTest.php
File
- src/
Tests/ RecipeWebTestBase.php, line 27
Class
- RecipeWebTestBase
- Provides a base class for testing the functionality of the Recipe module.
Namespace
Drupal\recipe\TestsCode
public function setUp() {
// Enable modules required for testing.
parent::setUp(array(
'recipe',
'recipe_plaintext',
'recipe_html',
'recipe_recipeML',
'recipe_mastercook4',
'recipe_test',
));
// Create and log in the admin user with Recipe content permissions.
$this->adminUser = $this
->drupalCreateUser(array(
'create recipe content',
'edit any recipe content',
'import recipes',
'export recipes',
'administer site configuration',
'administer blocks',
));
$this
->drupalLogin($this->adminUser);
// Populate the unit list.
$this->unitList = recipe_get_units();
}