Skip to content

Commit

Permalink
Skip svg sanitize test if package is not installed
Browse files Browse the repository at this point in the history
  • Loading branch information
mpysiak committed Oct 29, 2024
1 parent 032b0a7 commit 99a5fd1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/Functional/ImageUploaderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ final class ImageUploaderTest extends WebTestCase
/** @test */
public function it_sanitizes_file_content_if_it_is_svg_mime_type(): void
{
if (!class_exists(\enshrined\svgSanitize\Sanitizer::class)) {
$this->markTestSkipped('This test requires "enshrined/svg-sanitize" package to be installed.');
}

self::$client = static::createClient();

$imageUploader = self::$kernel->getContainer()->get('sylius.image_uploader');
Expand Down

0 comments on commit 99a5fd1

Please sign in to comment.