Test asynchronous parts of Jasmine asynchronously
This commit is contained in:
@@ -7,7 +7,7 @@ getJasmineRequireObj().Env = function(j$) {
|
||||
|
||||
var catchExceptions = true;
|
||||
|
||||
var realSetTimeout = global.setTimeout;
|
||||
var realSetTimeout = j$.getGlobal().setTimeout;
|
||||
this.clock = new j$.Clock(global, new j$.DelayedFunctionScheduler());
|
||||
|
||||
this.spies_ = [];
|
||||
@@ -111,7 +111,7 @@ getJasmineRequireObj().Env = function(j$) {
|
||||
|
||||
function clearStack(fn) {
|
||||
currentSpecCallbackDepth++;
|
||||
if (currentSpecCallbackDepth > maximumSpecCallbackDepth) {
|
||||
if (currentSpecCallbackDepth >= maximumSpecCallbackDepth) {
|
||||
currentSpecCallbackDepth = 0;
|
||||
realSetTimeout(fn, 0);
|
||||
} else {
|
||||
|
||||
@@ -5,7 +5,7 @@ getJasmineRequireObj().Suite = function() {
|
||||
this.parentSuite = attrs.parentSuite;
|
||||
this.description = attrs.description;
|
||||
this.onStart = attrs.onStart || function() {};
|
||||
this.completeCallback = attrs.completeCallback || function() {};
|
||||
this.completeCallback = attrs.completeCallback || function() {}; // TODO: this is unused
|
||||
this.resultCallback = attrs.resultCallback || function() {};
|
||||
this.clearStack = attrs.clearStack || function(fn) {fn();};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user