mirror of
https://github.com/Llewellynvdm/nativefier.git
synced 2024-11-11 07:41:04 +00:00
Cleanup and skip png conversion test if not OSX
This commit is contained in:
parent
947a8c2a8b
commit
d6f6bfdfbf
@ -3,12 +3,19 @@ import 'source-map-support/register';
|
|||||||
|
|
||||||
import chai from 'chai';
|
import chai from 'chai';
|
||||||
import fs from 'fs';
|
import fs from 'fs';
|
||||||
|
import os from 'os';
|
||||||
import path from 'path';
|
import path from 'path';
|
||||||
import pngToIcns from './../../lib/pngToIcns';
|
import pngToIcns from './../../lib/pngToIcns';
|
||||||
|
|
||||||
let assert = chai.assert;
|
let assert = chai.assert;
|
||||||
|
|
||||||
|
// Prerequisite for test: to use OSX with sips, iconutil and imagemagick convert
|
||||||
|
|
||||||
function testConvertPng(pngName, done) {
|
function testConvertPng(pngName, done) {
|
||||||
|
if (os.platform() !== 'darwin') {
|
||||||
|
console.warn('Skipping png conversion tests, OSX is required');
|
||||||
|
done();
|
||||||
|
}
|
||||||
pngToIcns(path.join(__dirname, '../../', 'test-resources', pngName), (error, icnsPath) => {
|
pngToIcns(path.join(__dirname, '../../', 'test-resources', pngName), (error, icnsPath) => {
|
||||||
if (error) {
|
if (error) {
|
||||||
done(error);
|
done(error);
|
||||||
|
@ -3,7 +3,6 @@ import chai from 'chai';
|
|||||||
import fs from 'fs';
|
import fs from 'fs';
|
||||||
import path from 'path';
|
import path from 'path';
|
||||||
import nativefier from './../../lib/index';
|
import nativefier from './../../lib/index';
|
||||||
import _ from 'lodash';
|
|
||||||
import async from 'async';
|
import async from 'async';
|
||||||
tmp.setGracefulCleanup();
|
tmp.setGracefulCleanup();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user