You are here

public function DisplayPageTest::testPageResponses in Views (for Drupal 7) 8.3

Checks the behavior of the page for access denied/not found behaviours.

File

lib/Drupal/views/Tests/Plugin/DisplayPageTest.php, line 36
Definition of Drupal\views\Tests\Plugin\DisplayPageTest.

Class

DisplayPageTest
Tests the page display plugin.

Namespace

Drupal\views\Tests\Plugin

Code

public function testPageResponses() {
  $view = views_get_view('test_page_display');
  $this
    ->drupalGet('test_page_display_403');
  $this
    ->assertResponse(403);
  $this
    ->drupalGet('test_page_display_404');
  $this
    ->assertResponse(404);
}