You are here

public function QuickEditTest::testQuickEditEnabledForUnpublishedContent in Lightning Workflow 8.3

Tests that Quick Edit is enabled when viewing unpublished content.

File

tests/src/FunctionalJavascript/QuickEditTest.php, line 41

Class

QuickEditTest
Tests Lightning Workflow's integration with Quick Edit.

Namespace

Drupal\Tests\lightning_workflow\FunctionalJavascript

Code

public function testQuickEditEnabledForUnpublishedContent() {
  $page = $this
    ->getSession()
    ->getPage();
  $account = $this
    ->drupalCreateUser([
    'access content overview',
    'access in-place editing',
    'access contextual links',
    'edit any page content',
    'use editorial transition create_new_draft',
    'view any unpublished content',
  ]);
  $this
    ->drupalLogin($account);
  $title = $this
    ->drupalCreateNode([
    'type' => 'page',
  ])
    ->getTitle();
  $this
    ->drupalGet('/admin/content');
  $page
    ->clickLink($title);
  $this
    ->assertQuickEditEnabled();
}