HTML: Include top suite failures in the reported failure count

This commit is contained in:
Steve Gravrock
2021-12-03 08:18:18 -08:00
parent 40fac8b6a2
commit b8dabf96ff
3 changed files with 69 additions and 0 deletions

View File

@@ -41,6 +41,12 @@ jasmineRequire.HtmlReporter = function(j$) {
}
};
ResultsStateBuilder.prototype.jasmineDone = function(result) {
if (result.failedExpectations) {
this.failureCount += result.failedExpectations.length;
}
};
function HtmlReporter(options) {
var config = function() {
return (options.env && options.env.configuration()) || {};
@@ -156,6 +162,7 @@ jasmineRequire.HtmlReporter = function(j$) {
};
this.jasmineDone = function(doneResult) {
stateBuilder.jasmineDone(doneResult);
var banner = find('.jasmine-banner');
var alert = find('.jasmine-alert');
var order = doneResult && doneResult.order;