Skip to content

Commit 7c016b9

Browse files
author
b4dnewz
committed
Added super simple test for buffers as input
1 parent 080d56f commit 7c016b9

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

test/buffer.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
var should = require("should");
2+
var parser = require('./main');
3+
4+
describe('Test buffers', function() {
5+
6+
it('handles buffers as input', function() {
7+
var buffer = new Buffer('echo "test"');
8+
var ast = parser.parseEval(buffer);
9+
ast.children[0].kind.should.be.exactly('echo');
10+
});
11+
12+
});

0 commit comments

Comments
 (0)