You are here

protected function AutosaveFormTest::pressRejectButton in Thunder 8.5

Same name and namespace in other branches
  1. 8.3 tests/src/FunctionalJavascript/Integration/AutosaveFormTest.php \Drupal\Tests\thunder\FunctionalJavascript\Integration\AutosaveFormTest::pressRejectButton()
  2. 8.4 tests/src/FunctionalJavascript/Integration/AutosaveFormTest.php \Drupal\Tests\thunder\FunctionalJavascript\Integration\AutosaveFormTest::pressRejectButton()
  3. 6.2.x tests/src/FunctionalJavascript/Integration/AutosaveFormTest.php \Drupal\Tests\thunder\FunctionalJavascript\Integration\AutosaveFormTest::pressRejectButton()
  4. 6.0.x tests/src/FunctionalJavascript/Integration/AutosaveFormTest.php \Drupal\Tests\thunder\FunctionalJavascript\Integration\AutosaveFormTest::pressRejectButton()
  5. 6.1.x tests/src/FunctionalJavascript/Integration/AutosaveFormTest.php \Drupal\Tests\thunder\FunctionalJavascript\Integration\AutosaveFormTest::pressRejectButton()

Press the reject button.

1 call to AutosaveFormTest::pressRejectButton()
AutosaveFormTest::testAutosaveInExistingEntity in tests/src/FunctionalJavascript/Integration/AutosaveFormTest.php
Tests the autosave functionality in an existing article.

File

tests/src/FunctionalJavascript/Integration/AutosaveFormTest.php, line 85

Class

AutosaveFormTest
Tests the autosave support for nodes in Thunder.

Namespace

Drupal\Tests\thunder\FunctionalJavascript\Integration

Code

protected function pressRejectButton() {
  $page = $this
    ->getSession()
    ->getPage();

  // Press restore button.
  $this
    ->assertSession()
    ->waitForText('A version of this page you were editing at');
  $reject_button = $page
    ->find('css', '.autosave-form-reject-button');
  $reject_button
    ->press();
}