public function EsiTest::testHasSurrogateEsiCapability in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/http-kernel/Tests/HttpCache/EsiTest.php \Symfony\Component\HttpKernel\Tests\HttpCache\EsiTest::testHasSurrogateEsiCapability()
File
- vendor/
symfony/ http-kernel/ Tests/ HttpCache/ EsiTest.php, line 20
Class
Namespace
Symfony\Component\HttpKernel\Tests\HttpCacheCode
public function testHasSurrogateEsiCapability() {
$esi = new Esi();
$request = Request::create('/');
$request->headers
->set('Surrogate-Capability', 'abc="ESI/1.0"');
$this
->assertTrue($esi
->hasSurrogateCapability($request));
$request = Request::create('/');
$request->headers
->set('Surrogate-Capability', 'foobar');
$this
->assertFalse($esi
->hasSurrogateCapability($request));
$request = Request::create('/');
$this
->assertFalse($esi
->hasSurrogateCapability($request));
}