diff options
Diffstat (limited to 'test/parsing.js')
-rw-r--r-- | test/parsing.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/parsing.js b/test/parsing.js new file mode 100644 index 0000000..3d41939 --- /dev/null +++ b/test/parsing.js @@ -0,0 +1,14 @@ +var path = require('path'); +var assert = require('assert'); + +var Book = require('../').Book; + +describe('Book parsing', function () { + it('should correctly parse it from markdown', function() { + var LEXED = book1.summary; + + assert.equal(LEXED.chapters[0].path,'intro.md'); + assert.equal(LEXED.chapters[1].path,'test.md'); + assert.equal(LEXED.chapters[2].path,'test2.md'); + }); +}); |