public function UrlTest::testEntityUris in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/tests/Drupal/Tests/Core/UrlTest.php \Drupal\Tests\Core\UrlTest::testEntityUris()
Tests the fromUri() method with an entity: URI.
@covers ::fromUri
@dataProvider providerTestEntityUris
File
- core/
tests/ Drupal/ Tests/ Core/ UrlTest.php, line 584 - Contains \Drupal\Tests\Core\UrlTest.
Class
- UrlTest
- @coversDefaultClass \Drupal\Core\Url @group UrlTest
Namespace
Drupal\Tests\CoreCode
public function testEntityUris($uri, $options, $route_name, $route_parameters, $query, $fragment) {
$url = Url::fromUri($uri, $options);
$this
->assertSame($route_name, $url
->getRouteName());
$this
->assertEquals($route_parameters, $url
->getRouteParameters());
$this
->assertEquals($url
->getOption('query'), $query);
$this
->assertSame($url
->getOption('fragment'), $fragment);
}