function PreviewTest::clickPreviewLinkAJAX

Same name in other branches
  1. 8.9.x core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php \Drupal\Tests\views_ui\FunctionalJavascript\PreviewTest::clickPreviewLinkAJAX()
  2. 10 core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php \Drupal\Tests\views_ui\FunctionalJavascript\PreviewTest::clickPreviewLinkAJAX()
  3. 11.x core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php \Drupal\Tests\views_ui\FunctionalJavascript\PreviewTest::clickPreviewLinkAJAX()

Click on a preview link.

Parameters

\Behat\Mink\Element\NodeElement $element: The element to click.

int $row_count: The expected number of rows in the preview.

1 call to PreviewTest::clickPreviewLinkAJAX()
PreviewTest::testPreviewWithPagersUI in core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php
Tests pagers in the preview form.

File

core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php, line 275

Class

PreviewTest
Tests the UI preview functionality.

Namespace

Drupal\Tests\views_ui\FunctionalJavascript

Code

protected function clickPreviewLinkAJAX(NodeElement $element, $row_count) {
    $element->click();
    $this->assertSession()
        ->assertWaitOnAjaxRequest();
    $this->assertPreviewAJAX($row_count);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.