function PathTaxonomyTermTest::setUp
Same name in other branches
- 9 core/modules/path/tests/src/Functional/PathTaxonomyTermTest.php \Drupal\Tests\path\Functional\PathTaxonomyTermTest::setUp()
- 10 core/modules/path/tests/src/Functional/PathTaxonomyTermTest.php \Drupal\Tests\path\Functional\PathTaxonomyTermTest::setUp()
- 11.x core/modules/path/tests/src/Functional/PathTaxonomyTermTest.php \Drupal\Tests\path\Functional\PathTaxonomyTermTest::setUp()
Overrides PathTestBase::setUp
File
-
core/
modules/ path/ tests/ src/ Functional/ PathTaxonomyTermTest.php, line 27
Class
- PathTaxonomyTermTest
- Tests URL aliases for taxonomy terms.
Namespace
Drupal\Tests\path\FunctionalCode
protected function setUp() {
parent::setUp();
// Create a Tags vocabulary for the Article node type.
$vocabulary = Vocabulary::create([
'name' => t('Tags'),
'vid' => 'tags',
]);
$vocabulary->save();
// Create and log in user.
$web_user = $this->drupalCreateUser([
'administer url aliases',
'administer taxonomy',
'access administration pages',
]);
$this->drupalLogin($web_user);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.