Fixed global error handler stack corruption in Jasmine's own tests

This commit is contained in:
Steve Gravrock
2020-09-02 09:31:35 -07:00
parent 5a715aecee
commit 00feef8632
14 changed files with 833 additions and 985 deletions

View File

@@ -1,4 +1,6 @@
getJasmineRequireObj().QueueRunner = function(j$) {
var nextid = 1;
function StopExecutionError() {}
StopExecutionError.prototype = new Error();
j$.StopExecutionError = StopExecutionError;
@@ -18,6 +20,7 @@ getJasmineRequireObj().QueueRunner = function(j$) {
function emptyFn() {}
function QueueRunner(attrs) {
this.id_ = nextid++;
var queueableFns = attrs.queueableFns || [];
this.queueableFns = queueableFns.concat(attrs.cleanupFns || []);
this.firstCleanupIx = queueableFns.length;