You are here

protected function EntityReferenceRevisionsAdminTest::setUp in Entity Reference Revisions 8

Overrides BrowserTestBase::setUp

File

tests/src/Functional/EntityReferenceRevisionsAdminTest.php, line 39

Class

EntityReferenceRevisionsAdminTest
Tests the entity_reference_revisions configuration.

Namespace

Drupal\Tests\entity_reference_revisions\Functional

Code

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

  // Create paragraphs and article content types.
  $this
    ->drupalCreateContentType(array(
    'type' => 'entity_revisions',
    'name' => 'Entity revisions',
  ));
  $this
    ->drupalCreateContentType(array(
    'type' => 'article',
    'name' => 'Article',
  ));

  // Place the breadcrumb, tested in fieldUIAddNewField().
  $this
    ->drupalPlaceBlock('system_breadcrumb_block');
  $admin_user = $this
    ->drupalCreateUser(array(
    'administer site configuration',
    'administer nodes',
    'create article content',
    'administer content types',
    'administer node fields',
    'administer node display',
    'administer node form display',
    'edit any article content',
  ));
  $this
    ->drupalLogin($admin_user);
}