ImageGdTest.php 640 Bytes
Newer Older
Antonio Ramirez committed
1 2 3 4 5 6 7 8 9 10 11 12
<?php

namespace yiiunit\extensions\imagine;

use yii\imagine\Image;

/**
 * @group vendor
 * @group imagine
 */
class ImageGdTest extends AbstractImageTest
{
13 14 15 16 17 18 19 20 21 22
    protected function setUp()
    {
        if (!function_exists('gd_info')) {
            $this->markTestSkipped('Skipping ImageGdTest, Gd not installed');
        } else {
            Image::setImagine(null);
            Image::$driver = Image::DRIVER_GD2;
            parent::setUp();
        }
    }
Antonio Ramirez committed
23

24 25 26 27 28 29
    protected function isFontTestSupported()
    {
        $infos = gd_info();

        return isset($infos['FreeType Support']) ? $infos['FreeType Support'] : false;
    }
30
}