Comparing version 0.2.3 to 0.2.4
@@ -72,2 +72,5 @@ var EventEmitter = require('events').EventEmitter; | ||
}; | ||
cb.ok = cb.bind(cb, null); | ||
f.apply(cb, context.stack); | ||
@@ -74,0 +77,0 @@ } |
{ | ||
"name" : "seq", | ||
"version" : "0.2.3", | ||
"version" : "0.2.4", | ||
"description" : "Chainable asynchronous flow control with sequential and parallel primitives and pipeline-style error handling", | ||
@@ -5,0 +5,0 @@ "main" : "./index.js", |
@@ -146,3 +146,3 @@ var Seq = require('seq'); | ||
assert.fail('error not caught'); | ||
}, 100); | ||
}, 5000); | ||
@@ -706,1 +706,20 @@ Seq() | ||
}; | ||
exports.ok = function () { | ||
var to = setTimeout(function () { | ||
assert.fail('seq never fired'); | ||
}, 500); | ||
function moo1 (cb) { cb(3) } | ||
function moo2 (cb) { cb(4) } | ||
Seq() | ||
.par(function () { moo1(this.ok) }) | ||
.par(function () { moo2(this.ok) }) | ||
.seq(function (x, y) { | ||
clearTimeout(to); | ||
assert.eql(x, 3); | ||
assert.eql(y, 4); | ||
}) | ||
; | ||
}; |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
59347
20
1521
337
4