You are here

protected function FileFieldWidgetTest::setUp in Drupal 9

Same name in this branch
  1. 9 core/modules/file/tests/src/Functional/FileFieldWidgetTest.php \Drupal\Tests\file\Functional\FileFieldWidgetTest::setUp()
  2. 9 core/modules/file/tests/src/FunctionalJavascript/FileFieldWidgetTest.php \Drupal\Tests\file\FunctionalJavascript\FileFieldWidgetTest::setUp()
Same name and namespace in other branches
  1. 8 core/modules/file/tests/src/FunctionalJavascript/FileFieldWidgetTest.php \Drupal\Tests\file\FunctionalJavascript\FileFieldWidgetTest::setUp()
  2. 10 core/modules/file/tests/src/FunctionalJavascript/FileFieldWidgetTest.php \Drupal\Tests\file\FunctionalJavascript\FileFieldWidgetTest::setUp()

Overrides BrowserTestBase::setUp

File

core/modules/file/tests/src/FunctionalJavascript/FileFieldWidgetTest.php, line 43

Class

FileFieldWidgetTest
Tests the file field widget, single and multi-valued, using AJAX upload.

Namespace

Drupal\Tests\file\FunctionalJavascript

Code

protected function setUp() : void {
  parent::setUp();
  $this->adminUser = $this
    ->drupalCreateUser([
    'access content',
    'access administration pages',
    'administer site configuration',
    'administer users',
    'administer permissions',
    'administer content types',
    'administer node fields',
    'administer node display',
    'administer nodes',
    'bypass node access',
  ]);
  $this
    ->drupalLogin($this->adminUser);
  $this
    ->drupalCreateContentType([
    'type' => 'article',
    'name' => 'Article',
  ]);
}