You are here

public function RequestTest::testGetBaseUrl in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-foundation/Tests/RequestTest.php \Symfony\Component\HttpFoundation\Tests\RequestTest::testGetBaseUrl()

@dataProvider getBaseUrlData

File

vendor/symfony/http-foundation/Tests/RequestTest.php, line 1429

Class

RequestTest

Namespace

Symfony\Component\HttpFoundation\Tests

Code

public function testGetBaseUrl($uri, $server, $expectedBaseUrl, $expectedPathInfo) {
  $request = Request::create($uri, 'GET', array(), array(), array(), $server);
  $this
    ->assertSame($expectedBaseUrl, $request
    ->getBaseUrl(), 'baseUrl');
  $this
    ->assertSame($expectedPathInfo, $request
    ->getPathInfo(), 'pathInfo');
}