You are here

public function PathProcessorFrontTest::providerProcessInbound in Drupal 9

Same name and namespace in other branches
  1. 8 core/tests/Drupal/Tests/Core/PathProcessor/PathProcessorFrontTest.php \Drupal\Tests\Core\PathProcessor\PathProcessorFrontTest::providerProcessInbound()
  2. 10 core/tests/Drupal/Tests/Core/PathProcessor/PathProcessorFrontTest.php \Drupal\Tests\Core\PathProcessor\PathProcessorFrontTest::providerProcessInbound()

Inbound paths and expected results.

File

core/tests/Drupal/Tests/Core/PathProcessor/PathProcessorFrontTest.php, line 42

Class

PathProcessorFrontTest
Test front page path processing.

Namespace

Drupal\Tests\Core\PathProcessor

Code

public function providerProcessInbound() {
  return [
    'accessing frontpage' => [
      '/node',
      '/',
      '/node',
    ],
    'accessing non frontpage' => [
      '/node',
      '/user',
      '/user',
    ],
    'accessing frontpage with query parameters' => [
      '/node?example=muh',
      '/',
      '/node',
      [
        'example' => 'muh',
      ],
    ],
  ];
}