You are here

private function ServiceControllerTest::assertDestinationSetFromReturnTo in CAS 8

Same name and namespace in other branches
  1. 2.x tests/src/Unit/Controller/ServiceControllerTest.php \Drupal\Tests\cas\Unit\Controller\ServiceControllerTest::assertDestinationSetFromReturnTo()

Assert that the destination query param is set when returnto is present.

3 calls to ServiceControllerTest::assertDestinationSetFromReturnTo()
ServiceControllerTest::testMissingTicketRedirectsHome in tests/src/Unit/Controller/ServiceControllerTest.php
Tests that we redirect to the homepage when no service ticket is present.
ServiceControllerTest::testSuccessfulLogin in tests/src/Unit/Controller/ServiceControllerTest.php
Tests that validation and logging in occurs when a ticket is present.
ServiceControllerTest::testSuccessfulLoginProxyEnabled in tests/src/Unit/Controller/ServiceControllerTest.php
Tests that a user is validated and logged in with Drupal acting as proxy.

File

tests/src/Unit/Controller/ServiceControllerTest.php, line 579

Class

ServiceControllerTest
ServiceController unit tests.

Namespace

Drupal\Tests\cas\Unit\Controller

Code

private function assertDestinationSetFromReturnTo() {
  $this->queryBag
    ->expects($this
    ->once())
    ->method('set')
    ->with('destination')
    ->will($this
    ->returnValue('node/1'));
}