MCPcopy Index your code
hub / github.com/prototypejs/prototype / next

Function next

test/unit/static/js/mocha.js:4365–4388  ·  view source on GitHub ↗
(i)

Source from the content-addressed store, hash-verified

4363 , timer;
4364
4365 function next(i) {
4366 var hook = hooks[i];
4367 if (!hook) return fn();
4368 if (self.failures && suite.bail()) return fn();
4369 self.currentRunnable = hook;
4370
4371 hook.ctx.currentTest = self.test;
4372
4373 self.emit('hook', hook);
4374
4375 hook.on('error', function(err){
4376 self.failHook(hook, err);
4377 });
4378
4379 hook.run(function(err){
4380 hook.removeAllListeners('error');
4381 var testError = hook.error();
4382 if (testError) self.fail(self.test, testError);
4383 if (err) return self.failHook(hook, err);
4384 self.emit('hook end', hook);
4385 delete hook.ctx.currentTest;
4386 next(++i);
4387 });
4388 }
4389
4390 Runner.immediately(function(){
4391 next(0);

Callers 1

mocha.jsFile · 0.70

Calls 1

doneFunction · 0.85

Tested by

no test coverage detected