function DisplayCRUDTest::testDefaultDisplay

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

Tests that the correct display is loaded by default.

File

core/modules/views_ui/tests/src/Functional/DisplayCRUDTest.php, line 107

Class

DisplayCRUDTest
Tests creation, retrieval, updating, and deletion of displays in the Web UI.

Namespace

Drupal\Tests\views_ui\Functional

Code

public function testDefaultDisplay() {
    $this->drupalGet('admin/structure/views/view/test_display');
    $this->assertSession()
        ->elementsCount('xpath', '//*[@id="views-page-1-display-title"]', 1);
}

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