function PathValidatorTest::setUp

Same name in this branch
  1. main core/tests/Drupal/KernelTests/Core/Path/PathValidatorTest.php \Drupal\KernelTests\Core\Path\PathValidatorTest::setUp()
Same name and namespace in other branches
  1. 11.x core/tests/Drupal/KernelTests/Core/Path/PathValidatorTest.php \Drupal\KernelTests\Core\Path\PathValidatorTest::setUp()
  2. 11.x core/tests/Drupal/Tests/Core/Path/PathValidatorTest.php \Drupal\Tests\Core\Path\PathValidatorTest::setUp()
  3. 10 core/tests/Drupal/KernelTests/Core/Path/PathValidatorTest.php \Drupal\KernelTests\Core\Path\PathValidatorTest::setUp()
  4. 10 core/tests/Drupal/Tests/Core/Path/PathValidatorTest.php \Drupal\Tests\Core\Path\PathValidatorTest::setUp()
  5. 9 core/tests/Drupal/KernelTests/Core/Path/PathValidatorTest.php \Drupal\KernelTests\Core\Path\PathValidatorTest::setUp()
  6. 9 core/tests/Drupal/Tests/Core/Path/PathValidatorTest.php \Drupal\Tests\Core\Path\PathValidatorTest::setUp()
  7. 8.9.x core/tests/Drupal/KernelTests/Core/Path/PathValidatorTest.php \Drupal\KernelTests\Core\Path\PathValidatorTest::setUp()
  8. 8.9.x core/tests/Drupal/Tests/Core/Path/PathValidatorTest.php \Drupal\Tests\Core\Path\PathValidatorTest::setUp()

Overrides UnitTestCase::setUp

File

core/tests/Drupal/Tests/Core/Path/PathValidatorTest.php, line 67

Class

PathValidatorTest
Tests Drupal\Core\Path\PathValidator.

Namespace

Drupal\Tests\Core\Path

Code

protected function setUp() : void {
  parent::setUp();
  $this->accessAwareRouter = $this->createStub(AccessAwareRouterInterface::class);
  $this->accessUnawareRouter = $this->createStub(UrlMatcherInterface::class);
  $this->account = $this->createStub(AccountInterface::class);
  $this->pathProcessor = $this->createStub(InboundPathProcessorInterface::class);
  $this->pathValidator = new PathValidator($this->accessAwareRouter, $this->accessUnawareRouter, $this->account, $this->pathProcessor);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.