Send unfocused tests through the same queue as focused tests

This commit is contained in:
Jonathan
2017-07-23 09:01:15 -07:00
parent 4cce7263c4
commit 7dfc5f506c
2 changed files with 19 additions and 13 deletions

View File

@@ -50,22 +50,25 @@ getJasmineRequireObj().Spec = function(j$) {
this.onStart(this);
if (!this.isExecutable() || this.markedPending || enabled === false) {
complete(enabled);
return;
}
var fns = this.beforeAndAfterFns();
var regularFns = fns.befores.concat(this.queueableFn);
this.queueRunnerFactory({
var runnerConfig = {
isLeaf: true,
queueableFns: regularFns,
cleanupFns: fns.afters,
onException: function() { self.onException.apply(self, arguments); },
onComplete: complete,
userContext: this.userContext()
});
};
if (!this.isExecutable() || this.markedPending || enabled === false) {
runnerConfig.queueableFns = [];
runnerConfig.cleanupFns = [];
runnerConfig.onComplete = function() { complete(enabled); };
}
this.queueRunnerFactory(runnerConfig);
function complete(enabledAgain) {
self.result.status = self.status(enabledAgain);