v1.18.x
Barış Soner Uşaklı 8 years ago
parent 8eb5564977
commit 932247f440

@ -18,8 +18,8 @@
},
"dependencies": {
"ace-builds": "^1.2.6",
"async": "2.4.0",
"autoprefixer": "7.0.1",
"async": "2.4.1",
"autoprefixer": "7.1.1",
"bcryptjs": "2.4.3",
"body-parser": "^1.9.0",
"bootstrap": "^3.3.7",
@ -39,9 +39,9 @@
"express": "^4.14.0",
"express-session": "^1.8.2",
"express-useragent": "1.0.7",
"html-to-text": "3.2.0",
"html-to-text": "3.3.0",
"ip": "1.1.5",
"jimp": "0.2.27",
"jimp": "0.2.28",
"jquery": "^3.1.0",
"json-2-csv": "^2.0.22",
"less": "^2.0.0",
@ -51,7 +51,7 @@
"mime": "^1.3.4",
"minimist": "^1.1.1",
"mkdirp": "~0.5.0",
"mongodb": "2.2.26",
"mongodb": "2.2.27",
"morgan": "^1.3.2",
"mousetrap": "^1.5.3",
"nconf": "~0.8.2",
@ -85,10 +85,10 @@
"semver": "^5.1.0",
"serve-favicon": "^2.1.5",
"sitemap": "^1.4.0",
"socket.io": "1.7.4",
"socket.io-client": "1.7.4",
"socket.io-redis": "4.0.0",
"socketio-wildcard": "0.4.0",
"socket.io": "2.0.1",
"socket.io-client": "2.0.1",
"socket.io-redis": "5.0.1",
"socketio-wildcard": "2.0.0",
"string": "^3.0.0",
"templates.js": "0.3.10",
"toobusy-js": "^0.5.1",

@ -18,4 +18,21 @@ describe('image', function () {
});
});
});
it('should resize an image', function (done) {
image.resizeImage({
path: path.join(__dirname, 'files/normalise.jpg'),
target: path.join(__dirname, 'files/normalise-resized.jpg'),
width: 50,
height: 40,
}, function (err) {
assert.ifError(err);
image.size(path.join(__dirname, 'files/normalise-resized.jpg'), function (err, bitmap) {
assert.ifError(err);
assert.equal(bitmap.width, 50);
assert.equal(bitmap.height, 40);
done();
});
});
});
});

Loading…
Cancel
Save