Permit focused running with Queue-based runner

This commit is contained in:
ragaskar 2009-08-19 07:55:51 -07:00
parent 0a3358f249
commit 2a4241323d
2 changed files with 11 additions and 7 deletions

View File

@ -48,8 +48,14 @@
var jasmineEnv = jasmine.getEnv();
jasmineEnv.addReporter(new jasmine.TrivialReporter());
var trivialReporter = new jasmine.TrivialReporter();
jasmineEnv.addReporter(trivialReporter);
jasmineEnv.specFilter = function(spec) {
return trivialReporter.specFilter(spec);
};
window.onload = function() {
jasmineEnv.execute();
};
</script>
</body>

View File

@ -14,7 +14,6 @@ jasmine.Spec = function(env, suite, description) {
spec.description = description;
spec.queue = new jasmine.Queue(env);
spec.finished = false;
spec.afterCallbacks = [];
spec.spies_ = [];
@ -117,8 +116,7 @@ jasmine.Spec.prototype.execute = function(onComplete) {
var spec = this;
if (!spec.env.specFilter(spec)) {
spec.results.skipped = true;
spec.finishCallback();
spec.finished = true;
spec.finish(onComplete);
return;
}