function PreviewTest::getPreviewAJAX
Same name in other branches
- 9 core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php \Drupal\Tests\views_ui\FunctionalJavascript\PreviewTest::getPreviewAJAX()
- 8.9.x core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php \Drupal\Tests\views_ui\FunctionalJavascript\PreviewTest::getPreviewAJAX()
- 11.x core/modules/views_ui/tests/src/FunctionalJavascript/PreviewTest.php \Drupal\Tests\views_ui\FunctionalJavascript\PreviewTest::getPreviewAJAX()
Get the preview form and force an AJAX preview update.
Parameters
string $view_name: The view to test.
string $panel_id: The view panel to test.
int $row_count: The expected number of rows in the preview.
3 calls to PreviewTest::getPreviewAJAX()
- PreviewTest::testPreviewSortLink in core/
modules/ views_ui/ tests/ src/ FunctionalJavascript/ PreviewTest.php - Tests the link to sort in the preview form.
- PreviewTest::testPreviewWithPagersUI in core/
modules/ views_ui/ tests/ src/ FunctionalJavascript/ PreviewTest.php - Tests pagers in the preview form.
- PreviewTest::testTaxonomyAJAX in core/
modules/ views_ui/ tests/ src/ FunctionalJavascript/ PreviewTest.php - Tests the taxonomy term preview AJAX.
File
-
core/
modules/ views_ui/ tests/ src/ FunctionalJavascript/ PreviewTest.php, line 262
Class
- PreviewTest
- Tests the UI preview functionality.
Namespace
Drupal\Tests\views_ui\FunctionalJavascriptCode
protected function getPreviewAJAX($view_name, $panel_id, $row_count) {
$this->drupalGet('admin/structure/views/view/' . $view_name . '/edit/' . $panel_id);
$this->getSession()
->getPage()
->pressButton('Update preview');
$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.