You are here

protected function ConfigTranslationDateFormatUiTest::setUp in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/config_translation/tests/src/Functional/ConfigTranslationDateFormatUiTest.php \Drupal\Tests\config_translation\Functional\ConfigTranslationDateFormatUiTest::setUp()
  2. 9 core/modules/config_translation/tests/src/Functional/ConfigTranslationDateFormatUiTest.php \Drupal\Tests\config_translation\Functional\ConfigTranslationDateFormatUiTest::setUp()

File

core/modules/config_translation/tests/src/Functional/ConfigTranslationDateFormatUiTest.php, line 26

Class

ConfigTranslationDateFormatUiTest
Tests the content translation behaviors on date formats.

Namespace

Drupal\Tests\config_translation\Functional

Code

protected function setUp() : void {
  parent::setUp();

  // Enable additional languages.
  $langcodes = [
    'de',
    'es',
  ];
  foreach ($langcodes as $langcode) {
    ConfigurableLanguage::createFromLangcode($langcode)
      ->save();
  }
  $user = $this
    ->drupalCreateUser([
    'administer site configuration',
    'translate configuration',
  ]);
  $this
    ->drupalLogin($user);
}