You are here

public function EsiTest::testAddSurrogateEsiCapability in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-kernel/Tests/HttpCache/EsiTest.php \Symfony\Component\HttpKernel\Tests\HttpCache\EsiTest::testAddSurrogateEsiCapability()

File

vendor/symfony/http-kernel/Tests/HttpCache/EsiTest.php, line 36

Class

EsiTest

Namespace

Symfony\Component\HttpKernel\Tests\HttpCache

Code

public function testAddSurrogateEsiCapability() {
  $esi = new Esi();
  $request = Request::create('/');
  $esi
    ->addSurrogateCapability($request);
  $this
    ->assertEquals('symfony2="ESI/1.0"', $request->headers
    ->get('Surrogate-Capability'));
  $esi
    ->addSurrogateCapability($request);
  $this
    ->assertEquals('symfony2="ESI/1.0", symfony2="ESI/1.0"', $request->headers
    ->get('Surrogate-Capability'));
}