mirror of
https://github.com/wallabag/wallabag.git
synced 2025-02-16 18:55:15 +00:00
Add some basic test
This commit is contained in:
parent
1b9e1d4886
commit
0049ef390b
2 changed files with 2 additions and 1 deletions
|
@ -351,7 +351,7 @@ class DownloadImages
|
|||
$this->logger->debug('DownloadImages: Checking extension (alternative)', ['ext' => $ext]);
|
||||
}
|
||||
|
||||
if (!\in_array($ext, ['jpeg', 'jpg', 'gif', 'png','webp'], true)) {
|
||||
if (!\in_array($ext, ['jpeg', 'jpg', 'gif', 'png', 'webp'], true)) {
|
||||
$this->logger->error('DownloadImages: Processed image with not allowed extension. Skipping: ' . $imagePath);
|
||||
|
||||
return false;
|
||||
|
|
|
@ -65,6 +65,7 @@ class DownloadImagesTest extends TestCase
|
|||
['image/jpeg', 'jpeg'],
|
||||
['image/png', 'png'],
|
||||
['image/gif', 'gif'],
|
||||
['image/webp', 'webp'],
|
||||
];
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue