You are here

protected function FormTestBase::getPath in Purge 8.3

Get a path string for the form route.

Parameters

array $route_parameters: (optional) An associative array of route parameter names and values.

array $options: See \Drupal\Core\Url::fromUri() for details.

Return value

string A new string created by Url::fromRoute()

See also

\Drupal\Core\Url::fromRoute()

55 calls to FormTestBase::getPath()
AjaxFormTestBase::postAjaxForm in modules/purge_ui/tests/src/Functional/Form/AjaxFormTestBase.php
Submits a ajax form through http_kernel.
AjaxFormTestBase::testAjaxDialog in modules/purge_ui/tests/src/Functional/Form/AjaxFormTestBase.php
Tests that forms have the Ajax dialog library loaded.
FormTestBase::getBuiltForm in modules/purge_ui/tests/src/Functional/Form/FormTestBase.php
Fetch a built form array fetched via its controller.
FormTestBase::testRouteAccess in modules/purge_ui/tests/src/Functional/Form/FormTestBase.php
Test that the form route isn't accessible anonymously or on bad routes.
FormTestBase::testRouteAccessGranted in modules/purge_ui/tests/src/Functional/Form/FormTestBase.php
Tests that the form route isn't accessible anonymously.

... See full list

File

modules/purge_ui/tests/src/Functional/Form/FormTestBase.php, line 198

Class

FormTestBase
Testbase for purge_ui forms.

Namespace

Drupal\Tests\purge_ui\Functional\Form

Code

protected function getPath(array $route_parameters = [], array $options = []) : string {
  $this
    ->propagateRouteParameters($route_parameters);
  return Url::fromRoute($this->route, $route_parameters, $options)
    ->toString();
}