You are here

public function EsiTest::testProcessDoesNothingIfContentTypeIsNotHtml 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::testProcessDoesNothingIfContentTypeIsNotHtml()

File

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

Class

EsiTest

Namespace

Symfony\Component\HttpKernel\Tests\HttpCache

Code

public function testProcessDoesNothingIfContentTypeIsNotHtml() {
  $esi = new Esi();
  $request = Request::create('/');
  $response = new Response();
  $response->headers
    ->set('Content-Type', 'text/plain');
  $esi
    ->process($request, $response);
  $this
    ->assertFalse($response->headers
    ->has('x-body-eval'));
}