From a05b3227091b37974e4942636f9984984a5aec2a Mon Sep 17 00:00:00 2001 From: Tj Holowaychuk Date: Fri, 17 Sep 2010 17:59:13 -0700 Subject: [PATCH] Reporting on failure --- bench.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bench.js b/bench.js index 6b8874d57b..acb47da8d5 100644 --- a/bench.js +++ b/bench.js @@ -38,6 +38,9 @@ function report(prev, curr) { console.log(' \x1b[' + col + 'm%s\x1b[0m:', label); console.log(' \x1b[33mprev\x1b[0m: %d ms', p); console.log(' \x1b[33mcurr\x1b[0m: %d ms', c); + if (c > p) { + console.log(' previously was \x1b[33m%d\x1b[0m ms faster', c - p); + } } fs.writeFileSync(path, JSON.stringify(curr), 'ascii'); console.log();