Fix unit tests

This commit is contained in:
Damian Mooyman 2018-06-13 14:09:31 +12:00
parent aa1ba0ef90
commit 6f32762268
No known key found for this signature in database
GPG Key ID: 78B823A10DE27D1A
3 changed files with 2 additions and 3 deletions

View File

@ -92,7 +92,7 @@ class HTTPCacheControlMiddleware implements HTTPMiddleware, Resettable
*
* @var string
*/
protected $state = self::STATE_ENABLED;
protected $state = self::STATE_DISABLED;
/**
* Forcing level of previous setting; higher number wins

View File

@ -4,7 +4,6 @@ namespace SilverStripe\Control\Tests;
use SilverStripe\Control\HTTP;
use SilverStripe\Control\Middleware\HTTPCacheControlMiddleware;
use SilverStripe\Control\Session;
use SilverStripe\Control\Tests\HTTPCacheControlIntegrationTest\RuleController;
use SilverStripe\Control\Tests\HTTPCacheControlIntegrationTest\SessionController;
use SilverStripe\Core\Config\Config;

View File

@ -75,7 +75,7 @@ class HTTPTest extends FunctionalTest
$this->expectException(PHPUnit_Framework_Error_Warning::class);
$this->expectExceptionMessage(
'Cache-Control header has already been set. '
. 'Please use HTTPCacheControl API to set caching options instead.'
. 'Please use HTTPCacheControlMiddleware API to set caching options instead.'
);
HTTP::add_cache_headers($response);