Permalink
Browse files

add failing test with chaining on require

  • Loading branch information...
1 parent d70a95a commit fa9c09705cfe473f13dc0c2d843bcc24170cff9d @dominictarr dominictarr committed Apr 23, 2012
Showing with 14 additions and 0 deletions.
  1. +9 −0 test/chained.js
  2. +5 −0 test/files/chained.js
View
@@ -0,0 +1,9 @@
+var test = require('tap').test;
+var detective = require('../');
+var fs = require('fs');
+var src = fs.readFileSync(__dirname + '/files/chained.js');
+
+test('chained', function (t) {
+ t.deepEqual(detective(src), [ 'c', 'b', 'a' ]);
+ t.end();
+});
View
@@ -0,0 +1,5 @@
+
+
+require('c').hello().goodbye()
+require('b').hello()
+require('a')

0 comments on commit fa9c097

Please sign in to comment.