Permalink
Browse files

cb test fails at checking for current

  • Loading branch information...
1 parent fd559df commit e8c330247498580f341091ba5ef655afe0305e6c @substack committed Sep 20, 2011
Showing with 6 additions and 2 deletions.
  1. +6 −2 test/cb.js
View
@@ -5,14 +5,18 @@ var fs = require('fs');
var src = fs.readFileSync(__dirname + '/sources/cb.js', 'utf8');
test('cb', function (t) {
- t.plan(5);
+ t.plan(7);
var stack = stackedy(src).run({
fn : function (name, cb) {
t.equal(name, 'quoymielle')
cb({
ok : t.ok.bind(t),
equal : t.equal.bind(t),
- end : t.end.bind(t),
+ end : function () {
+ t.ok(stack.current);
+ t.equal(stack.current.source(), 't.end();');
+ t.end();
+ },
wuxxet : function (x, cb) {
t.equal(x, 'flibble');
cb('kallisti');

0 comments on commit e8c3302

Please sign in to comment.