You are here

private function BlockTest::assertPath in Search API Pages 8

Asserts that we are on the expected path.

Parameters

string $expectedPath: The expected path.

2 calls to BlockTest::assertPath()
BlockTest::testSearchForm in tests/src/Functional/BlockTest.php
Tests that the search form block works.
BlockTest::testSearchFormsSearchOnCorrectPage in tests/src/Functional/BlockTest.php
Tests search forms search on the correct page when multiple configured.

File

tests/src/Functional/BlockTest.php, line 92

Class

BlockTest
Provides web tests for Search API Pages.

Namespace

Drupal\Tests\search_api_page\Functional

Code

private function assertPath($expectedPath) {
  $url = $this
    ->buildUrl($expectedPath, [
    'absolute' => TRUE,
  ]);
  $this
    ->assertEquals($url, $this
    ->getSession()
    ->getCurrentUrl());
}