]> git.agnieray.net Git - galette.git/blobdiff - tests/Galette/Core/tests/units/Picture.php
Add WebP images support; closes #1681
[galette.git] / tests / Galette / Core / tests / units / Picture.php
index 4354f6b7866e0de967c0f72fbe5241d56e0e116e..5cb5c1a7a408c62705aa50ceed21e2f60a6de33b 100644 (file)
@@ -104,13 +104,14 @@ class Picture extends TestCase
         $this->assertNull($picture->getDestDir());
         $this->assertNull($picture->getFileName());
 
-        $expected_exts = ['jpeg', 'jpg', 'png', 'gif'];
+        $expected_exts = ['jpeg', 'jpg', 'png', 'gif', 'webp'];
         $this->assertSame(implode(', ', $expected_exts), $picture->getAllowedExts());
 
         $expected_mimes = [
             'jpg'    =>    'image/jpeg',
             'png'    =>    'image/png',
-            'gif'    =>    'image/gif'
+            'gif'    =>    'image/gif',
+            'webp'   =>    'image/webp'
         ];
         $this->assertSame($expected_mimes, $picture->getAllowedMimeTypes());
 
@@ -232,7 +233,7 @@ class Picture extends TestCase
             $this->picture->getErrorMessage(\Galette\Core\Picture::INVALID_FILENAME)
         );
         $this->assertSame(
-            'File extension is not allowed, only jpeg, jpg, png, gif files are.',
+            'File extension is not allowed, only jpeg, jpg, png, gif, webp files are.',
             $this->picture->getErrorMessage(\Galette\Core\Picture::INVALID_EXTENSION)
         );
         $this->assertSame(