From bb66df0560808e243f5cbb499aff582ccd40a622 Mon Sep 17 00:00:00 2001 From: Tj Holowaychuk Date: Fri, 12 Nov 2010 14:27:06 -0800 Subject: [PATCH] Normalizing state.png in tests --- test/server.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/server.js b/test/server.js index 124a773..1028d71 100644 --- a/test/server.js +++ b/test/server.js @@ -31,6 +31,10 @@ app.get('/', function(req, res){ }); app.post('/render', function(req, res, next){ + // Normalize state.png as ./public/state.png + // no good way around this at the moment + req.body.fn = req.body.fn.replace("'state.png'", "'" + __dirname + "/public/state.png'"); + // Do not try this at home :) var fn = eval('(' + req.body.fn + ')') , width = req.body.width