function LanguageFallbackTest::setUp
Same name in other branches
- 9 core/modules/language/tests/src/Kernel/LanguageFallbackTest.php \Drupal\Tests\language\Kernel\LanguageFallbackTest::setUp()
- 8.9.x core/modules/language/tests/src/Kernel/LanguageFallbackTest.php \Drupal\Tests\language\Kernel\LanguageFallbackTest::setUp()
- 10 core/modules/language/tests/src/Kernel/LanguageFallbackTest.php \Drupal\Tests\language\Kernel\LanguageFallbackTest::setUp()
Overrides LanguageTestBase::setUp
File
-
core/
modules/ language/ tests/ src/ Kernel/ LanguageFallbackTest.php, line 20
Class
- LanguageFallbackTest
- Tests the language fallback behavior.
Namespace
Drupal\Tests\language\KernelCode
protected function setUp() : void {
parent::setUp();
$i = 0;
foreach ([
'af',
'am',
'ar',
] as $langcode) {
$language = ConfigurableLanguage::createFromLangcode($langcode);
$language->set('weight', $i--);
$language->save();
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.