diff --git a/test/server.js b/test/server.js index ded5c9b..c431d9e 100644 --- a/test/server.js +++ b/test/server.js @@ -85,6 +85,8 @@ app.post('/pdf', function(req, res, next){ }); app.post('/jpeg', function(req, res, next){ + // Send nothing if jpeg isn't available. + if (!Canvas.jpegVersion) { return res.send({}).end(); } var fn = testFn(req) , canvas = createCanvas(req) , ctx = canvas.getContext('2d');