You are here

public function UrlValidatorTest::testRootToRelative in Mini site 8

Tests for rootToRelative().

@dataProvider dataProviderRootToRelative @covers \Drupal\minisite\UrlValidator::rootToRelative

File

tests/src/Kernel/UrlValidatorTest.php, line 165

Class

UrlValidatorTest
Class UrlValidatorTest.

Namespace

Drupal\Tests\minisite\Kernel

Code

public function testRootToRelative($url, $prefix, $expected) {
  $actual = UrlValidator::rootToRelative($url, $prefix);
  $this
    ->assertEquals($expected, $actual);
}