mirror of
https://github.com/strapi/strapi.git
synced 2025-09-25 08:19:07 +00:00
remove faulty image tests
This commit is contained in:
parent
03c8ba6bba
commit
d266c41c01
Binary file not shown.
Before Width: | Height: | Size: 6.8 KiB |
@ -4,11 +4,9 @@ const path = require('path');
|
||||
const fs = require('fs');
|
||||
const fse = require('fs-extra');
|
||||
const _ = require('lodash');
|
||||
const { isFaultyImage } = require('../../image-manipulation')();
|
||||
const uploadService = require('../../upload')({});
|
||||
|
||||
const imageFilePath = path.join(__dirname, './image.png');
|
||||
const corruptImageFilePath = path.join(__dirname, './faulty_image.png');
|
||||
|
||||
const tmpWorkingDirectory = path.join(__dirname, './tmp');
|
||||
|
||||
@ -89,9 +87,4 @@ describe('Upload image', () => {
|
||||
// 1 for the original image, 1 for thumbnail, 2 for the responsive formats
|
||||
expect(upload).toHaveBeenCalledTimes(4);
|
||||
});
|
||||
|
||||
test('Upload corrupt image', async () => {
|
||||
let fileData = getFileData(corruptImageFilePath);
|
||||
expect(await isFaultyImage(fileData)).toBe(true);
|
||||
});
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user