Fixed bug: waitsFor() hangs forever if latch function never returns true.

This commit is contained in:
Christian Williams
2010-08-25 17:16:19 -07:00
parent 254ebb8a03
commit 55149310c3
4 changed files with 11 additions and 4 deletions

View File

@@ -39,7 +39,9 @@ jasmine.WaitsForBlock.prototype.execute = function(onComplete) {
name: 'timeout',
message: message
});
// todo: need to prevent additional blocks in this spec from running... [xw 20100819]
this.abort = true;
onComplete();
} else {
this.totalTimeSpentWaitingForLatch += jasmine.WaitsForBlock.TIMEOUT_INCREMENT;
var self = this;