1
0
mirror of https://github.com/Intervention/image.git synced 2025-08-29 00:29:55 +02:00

Optimize tests

This commit is contained in:
Oliver Vogel
2024-12-06 17:32:55 +01:00
parent 69daa96f66
commit b9a16d4df6
120 changed files with 292 additions and 185 deletions

View File

@@ -4,21 +4,22 @@ declare(strict_types=1);
namespace Intervention\Image\Tests\Unit\Drivers\Imagick\Analyzers;
use Intervention\Image\Drivers\Imagick\Analyzers\ProfileAnalyzer;
use Intervention\Image\Drivers\Imagick\Driver;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\RequiresPhpExtension;
use Intervention\Image\Analyzers\ProfileAnalyzer;
use Intervention\Image\Exceptions\ColorException;
use Intervention\Image\Tests\ImagickTestCase;
#[RequiresPhpExtension('imagick')]
#[CoversClass(\Intervention\Image\Analyzers\ProfileAnalyzer::class)]
#[CoversClass(\Intervention\Image\Drivers\Imagick\Analyzers\ProfileAnalyzer::class)]
#[CoversClass(ProfileAnalyzer::class)]
final class ProfileAnalyzerTest extends ImagickTestCase
{
public function testAnalyze(): void
{
$image = $this->readTestImage('tile.png');
$analyzer = new ProfileAnalyzer();
$analyzer->setDriver(new Driver());
$this->expectException(ColorException::class);
$analyzer->analyze($image);
}