added initial suite value for the root suite in the mocha_reporter, in case a hook fails before the first suite is loaded

test/mocha_multi_reporter.js
This commit is contained in:
Spencer Alger
2013-11-13 16:29:11 -07:00
parent f8a34df5ae
commit 5e7e437162
3 changed files with 4 additions and 2 deletions

View File

@ -34,7 +34,8 @@
var stats = this.stats;
var rootSuite = {
$el: $('<ul id="mocha-report"></ul>'),
results: []
results: [],
suites: []
};

View File

@ -33,6 +33,7 @@
mocha.checkLeaks();
mocha.slow(1000);
mocha.timeout(11000);
mocha.globals(['console', 'elasticsearch']);
mocha.bail();
/PhantomJS/i.test(navigator.userAgent) || mocha.run();
</script>