mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
14 lines
403 B
JavaScript
14 lines
403 B
JavaScript
jasmine.WaitsBlock = function(env, timeout, spec) {
|
|
this.timeout = timeout;
|
|
jasmine.Block.call(this, env, null, spec);
|
|
};
|
|
|
|
jasmine.util.inherit(jasmine.WaitsBlock, jasmine.Block);
|
|
|
|
jasmine.WaitsBlock.prototype.execute = function (onComplete) {
|
|
this.env.reporter.log('>> Jasmine waiting for ' + this.timeout + ' ms...');
|
|
this.env.setTimeout(function () {
|
|
onComplete();
|
|
}, this.timeout);
|
|
};
|