You are here

public function AuthcacheP13nTestFrontcontroller::testMissingAuthcacheHeader in Authenticated User Page Caching (Authcache) 7.2

Fc should respond with 400 Bad Request if X-Authcache header is missing.

File

modules/authcache_p13n/tests/authcache_p13n.frontcontroller.test, line 117
Defines tests for authcache frontcontroller for personalized requests.

Class

AuthcacheP13nTestFrontcontroller
Tests for authcache frontcontroller for personalized requests.

Code

public function testMissingAuthcacheHeader() {
  $params = array(
    'r' => 'test/good',
    'q' => 'node',
  );
  $result = $this
    ->drupalGet($this->fcURL, array(
    'query' => $params,
  ));
  $this
    ->assertResponse(400);
  $this
    ->assertEqual('', $result);
}