Skip everything except afterAll fns when a beforeAll fn errors

* Fixes #1533
This commit is contained in:
Steve Gravrock
2021-09-30 10:19:58 -07:00
parent 5eaeeb0b6c
commit 5f1ef5ac2b
14 changed files with 316 additions and 70 deletions

View File

@@ -253,7 +253,16 @@ getJasmineRequireObj().TreeProcessor = function() {
return result;
}
return node.beforeAllFns.concat(result).concat(node.afterAllFns);
return node.beforeAllFns
.map(function(fn) {
return { type: 'beforeAll', ...fn };
})
.concat(result)
.concat(
node.afterAllFns.map(function(fn) {
return { type: 'afterAll', ...fn };
})
);
}
}