protected function CasBrowserTestBase::buildServiceUrlWithParams in CAS 2.x
Same name and namespace in other branches
- 8 tests/src/Functional/CasBrowserTestBase.php \Drupal\Tests\cas\Functional\CasBrowserTestBase::buildServiceUrlWithParams()
Helper function for constructing an expected service URL.
Any parameters passed into the optional array will be appended to the service URL.
Parameters
array $service_url_params: Parameters to include on the service url.
Return value
string URL in string format.
3 calls to CasBrowserTestBase::buildServiceUrlWithParams()
- CasForcedAuthSubscriberTest::testForcedLoginPaths in tests/src/ Functional/ CasForcedAuthSubscriberTest.php 
- Test that the CasSubscriber properly forces CAS authentication as expected.
- CasForcedLoginControllerTest::testForcedLoginRoute in tests/src/ Functional/ CasForcedLoginControllerTest.php 
- Tests the the forced login route that redirects users authenticate.
- CasGatewayAuthSubscriberTest::getExpectedRedirectUrl in tests/src/ Functional/ CasGatewayAuthSubscriberTest.php 
- Returns the expected redirect URL.
File
- tests/src/ Functional/ CasBrowserTestBase.php, line 49 
Class
- CasBrowserTestBase
- Tests the CAS forced login controller.
Namespace
Drupal\Tests\cas\FunctionalCode
protected function buildServiceUrlWithParams(array $service_url_params = []) {
  $service_url = $this->baseUrl . '/casservice';
  if (!empty($service_url_params)) {
    $encoded_params = UrlHelper::buildQuery($service_url_params);
    $service_url .= '?' . $encoded_params;
  }
  return $service_url;
}