You are here

public function SkipRedirectTest::testSkipRedirect in Redirect 403 to User Login 2.x

Same name and namespace in other branches
  1. 8 tests/src/Functional/SkipRedirectTest.php \Drupal\Tests\r4032login\Functional\SkipRedirectTest::testSkipRedirect()

Test that is well avoided to redirect for configured urls.

@dataProvider skipRedirectDataProvider

Parameters

string $path: Request path.

int $code: Response status code.

string $destination: Resulting URL.

Throws

\Behat\Mink\Exception\ExpectationException

File

tests/src/Functional/SkipRedirectTest.php, line 49

Class

SkipRedirectTest
Test that is well avoided to redirect for configured urls.

Namespace

Drupal\Tests\r4032login\Functional

Code

public function testSkipRedirect($path, $code, $destination) {
  $this
    ->drupalGet($path);
  $this
    ->assertSession()
    ->statusCodeEquals($code);
  $this
    ->assertSession()
    ->addressEquals($destination);
}