From a01100f5c6404366dd4219b9bf6c3161300dc735 Mon Sep 17 00:00:00 2001 From: johnjbarton Date: Thu, 26 Jun 2014 11:55:58 -0700 Subject: [PATCH] fix(logging): Summarize SKIPPED tests in debug.html. Before: hundreds of SKIPPING lines in console.log. After: A single summary line with a count. Closes #1111 --- static/debug.html | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/static/debug.html b/static/debug.html index 20311af02..df6828941 100644 --- a/static/debug.html +++ b/static/debug.html @@ -22,10 +22,17 @@ info: function(info) { if (info.dump && window.console) window.console.log(info.dump); }, - complete: function() {}, + complete: function() { + window.console.log('Skipped ' + this.skipped + ' tests'); + }, store: function() {}, + skipped: 0, result: window.console ? function(result) { - var msg = result.skipped ? 'SKIPPED ' : (result.success ? 'SUCCESS ' : 'FAILED '); + if (result.skipped) { + this.skipped++; + return; + } + var msg = result.success ? 'SUCCESS ' : 'FAILED '; window.console.log(msg + result.suite.join(' ') + ' ' + result.description); for (var i = 0; i < result.log.length; i++) {