diff options
Diffstat (limited to '485f75211335bfd69882bee7d3fccc730485aa82.patch')
-rw-r--r-- | 485f75211335bfd69882bee7d3fccc730485aa82.patch | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/485f75211335bfd69882bee7d3fccc730485aa82.patch b/485f75211335bfd69882bee7d3fccc730485aa82.patch new file mode 100644 index 0000000..7c5ae5d --- /dev/null +++ b/485f75211335bfd69882bee7d3fccc730485aa82.patch @@ -0,0 +1,41 @@ +From 485f75211335bfd69882bee7d3fccc730485aa82 Mon Sep 17 00:00:00 2001 +From: Frank de Jonge <info@frenky.net> +Date: Mon, 21 Sep 2020 20:19:38 +0200 +Subject: [PATCH] Assert start of string for SVG type, it varies based on PHP + version + +--- + src/FinfoMimeTypeDetectorTest.php | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/src/FinfoMimeTypeDetectorTest.php b/src/FinfoMimeTypeDetectorTest.php +index fadbe88..9f6c91b 100644 +--- a/src/FinfoMimeTypeDetectorTest.php ++++ b/src/FinfoMimeTypeDetectorTest.php +@@ -38,7 +38,7 @@ public function detecting_mime_type_from_contents(): void + + $mimeType = $this->detector->detectMimeType('flysystem.svg', $contents); + +- $this->assertEquals('image/svg', $mimeType); ++ $this->assertStringStartsWith('image/svg', $mimeType); + } + + /** +@@ -51,7 +51,7 @@ public function detecting_mime_type_from_buffer(): void + + $mimeType = $this->detector->detectMimeTypeFromBuffer($contents); + +- $this->assertEquals('image/svg', $mimeType); ++ $this->assertStringStartsWith('image/svg', $mimeType); + } + + /** +@@ -61,7 +61,7 @@ public function detecting_from_contents_falls_back_to_extension_detection(): voi + { + $mimeType = $this->detector->detectMimeType('flysystem.svg', ''); + +- $this->assertEquals('image/svg+xml', $mimeType); ++ $this->assertStringStartsWith('image/svg+xml', $mimeType); + } + + /** |