-
Notifications
You must be signed in to change notification settings - Fork 25
server side Node.js testing result
Leon Shi edited this page Dec 9, 2015
·
1 revision
image-clipper tests with node-canvas
✓ loadImageFromUrl(url, function() {...}) works
✓ loadImageFromMemory(img).crop(...) works
✓ destroy() works
✓ reset() works
✓ setImageFormat(imageFormat) works
✓ injectNodeCanvas(Canvas) works
✓ new ImageClipper() throws
✓ new ImageClipper({canvas: 12}) throws
crop
✓ crop(x, y, width, height) works
✓ crop(x, y, width, height).toDataURL(function(dataUrl) {...}) works
✓ crop(x, y, width, height).resize(width2, height2) works
✓ crop(x, y, width, height).toFile(...) works
✓ crop(x, y, width, height).resize(width2, height2).toFile(...) works
toDataURL
✓ toDataURL() throws
✓ toDataURL(quality) throws
✓ toDataURL(callback) works
✓ toDataURL(quality, callback) works
resize
✓ resize(width, height) works
✓ resize(width) works
✓ resize() throws
✓ resize(width, height).toFile(path, function() {...}) works
✓ resize(width).toFile(path, function() {...}) works
quality
✓ quality(level) works
✓ works when quality level > max quality level
✓ works when quality level < min quality level
utils
✓ isBrowser() works
✓ isNode() works
✓ isNW() works
✓ isElectron() works
✓ rangeNumber(num, min, max) works
✓ getImageFormat(str) works
✓ upperCaseFirstLetter(str) works