protected function VocabularyTranslationTest::setUp in Drupal 9
Same name and namespace in other branches
- 8 core/modules/taxonomy/tests/src/Functional/VocabularyTranslationTest.php \Drupal\Tests\taxonomy\Functional\VocabularyTranslationTest::setUp()
Overrides TaxonomyTestBase::setUp
File
- core/
modules/ taxonomy/ tests/ src/ Functional/ VocabularyTranslationTest.php, line 38
Class
- VocabularyTranslationTest
- Tests content translation for vocabularies.
Namespace
Drupal\Tests\taxonomy\FunctionalCode
protected function setUp() : void {
parent::setUp();
// Create an administrative user.
$this
->drupalLogin($this
->drupalCreateUser([
'administer taxonomy',
'administer content translation',
'translate configuration',
]));
// Add languages.
foreach ($this->additionalLangcodes as $langcode) {
ConfigurableLanguage::createFromLangcode($langcode)
->save();
}
}