function VocabularyLanguageTest::setUp
Overrides TaxonomyTestBase::setUp
File
- 
              core/modules/ taxonomy/ tests/ src/ Functional/ VocabularyLanguageTest.php, line 25 
Class
- VocabularyLanguageTest
- Tests the language functionality for vocabularies.
Namespace
Drupal\Tests\taxonomy\FunctionalCode
protected function setUp() : void {
  parent::setUp();
  // Create an administrative user.
  $this->drupalLogin($this->drupalCreateUser([
    'administer taxonomy',
  ]));
  // Add some custom languages.
  ConfigurableLanguage::create([
    'id' => 'aa',
    'label' => $this->randomMachineName(),
  ])
    ->save();
  ConfigurableLanguage::create([
    'id' => 'bb',
    'label' => $this->randomMachineName(),
  ])
    ->save();
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
