silverstripe-framework/tests/php/ORM/GDImageTest.php
2016-11-23 19:25:12 +13:00

32 lines
629 B
PHP

<?php
require_once(__DIR__ . "/ImageTest.php");
use SilverStripe\Core\Config\Config;
use SilverStripe\Core\Cache;
class GDImageTest extends ImageTest {
public function setUp() {
parent::setUp();
if(!extension_loaded("gd")) {
$this->markTestSkipped("The GD extension is required");
return;
}
/** @skipUpgrade */
Config::inst()->update(
'SilverStripe\\Core\\Injector\\Injector',
'Image_Backend',
'SilverStripe\\Assets\\GDBackend'
);
}
public function tearDown() {
$cache = Cache::factory('GDBackend_Manipulations');
$cache->clean(Zend_Cache::CLEANING_MODE_ALL);
parent::tearDown();
}
}