You are here

protected function ImageStylesPathAndUrlTest::setUp in Drupal 9

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

Overrides BrowserTestBase::setUp

File

core/modules/image/tests/src/Functional/ImageStylesPathAndUrlTest.php, line 46

Class

ImageStylesPathAndUrlTest
Tests the functions for generating paths and URLs for image styles.

Namespace

Drupal\Tests\image\Functional

Code

protected function setUp() : void {
  parent::setUp();
  $this->style = ImageStyle::create([
    'name' => 'style_foo',
    'label' => $this
      ->randomString(),
  ]);
  $this->style
    ->save();

  // Create a new language.
  ConfigurableLanguage::createFromLangcode('fr')
    ->save();
}