You are here

protected function EntityReferenceRevisionsDiffTest::setUp in Entity Reference Revisions 8

Overrides BrowserTestBase::setUp

File

tests/src/Functional/EntityReferenceRevisionsDiffTest.php, line 41

Class

EntityReferenceRevisionsDiffTest
Tests the entity_reference_revisions diff plugin.

Namespace

Drupal\Tests\entity_reference_revisions\Functional

Code

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

  // Create article content type.
  $this
    ->drupalCreateContentType([
    'type' => 'article',
    'name' => 'Article',
  ]);

  // Disable visual inline diff.
  $config = $this
    ->config('diff.settings')
    ->set('general_settings.layout_plugins.visual_inline.enabled', FALSE);
  $config
    ->save();
  $admin_user = $this
    ->drupalCreateUser([
    'administer site configuration',
    'administer nodes',
    'administer content types',
    'administer node fields',
    'administer node display',
    'administer node form display',
    'view all revisions',
    'edit any article content',
  ]);
  $this
    ->drupalLogin($admin_user);
  $this
    ->drupalPlaceBlock('system_breadcrumb_block');
}