You've already forked pigallery2
mirror of
https://github.com/bpatrik/pigallery2.git
synced 2025-07-15 01:24:25 +02:00
fixing linting erros. adding tslint to pretest
This commit is contained in:
@ -28,7 +28,7 @@ describe('PhotoProcessing', () => {
|
||||
{
|
||||
const convertedPath = PhotoProcessing.generateConvertedPath(photoPath,
|
||||
Config.Server.Media.Photo.Converting.resolution);
|
||||
Config.Server.Media.Photo.Converting.resolution = <any>1;
|
||||
Config.Server.Media.Photo.Converting.resolution = (1 as any);
|
||||
expect(await PhotoProcessing.isValidConvertedPath(convertedPath)).to.be.false;
|
||||
}
|
||||
});
|
||||
@ -37,13 +37,12 @@ describe('PhotoProcessing', () => {
|
||||
it('should generate converted thumbnail path', async () => {
|
||||
|
||||
Config.load();
|
||||
Config.Server.Media.Photo.Converting.resolution = <any>null;
|
||||
Config.Server.Media.Photo.Converting.resolution = (null as any);
|
||||
Config.Client.Media.Thumbnail.thumbnailSizes = [10, 20];
|
||||
ProjectPath.ImageFolder = path.join(__dirname, './../../../assets');
|
||||
const photoPath = path.join(ProjectPath.ImageFolder, 'test_png.png');
|
||||
|
||||
for (let i = 0; i < Config.Client.Media.Thumbnail.thumbnailSizes.length; ++i) {
|
||||
const thSize = Config.Client.Media.Thumbnail.thumbnailSizes[i];
|
||||
for (const thSize of Config.Client.Media.Thumbnail.thumbnailSizes) {
|
||||
expect(await PhotoProcessing
|
||||
.isValidConvertedPath(PhotoProcessing.generateConvertedPath(photoPath, thSize)))
|
||||
.to.be.true;
|
||||
|
Reference in New Issue
Block a user