diff options
author | Samy Pesse <samypesse@gmail.com> | 2016-04-30 22:06:16 +0200 |
---|---|---|
committer | Samy Pesse <samypesse@gmail.com> | 2016-04-30 22:06:16 +0200 |
commit | c1d53ec11fbe085932df911bda5686b7bf671f53 (patch) | |
tree | 97ae6db641eb79ec9b061af136a0b2e3c549db55 /test/locate.js | |
parent | 36b49c66c6b75515bc84dd678fd52121a313e8d2 (diff) | |
download | gitbook-c1d53ec11fbe085932df911bda5686b7bf671f53.zip gitbook-c1d53ec11fbe085932df911bda5686b7bf671f53.tar.gz gitbook-c1d53ec11fbe085932df911bda5686b7bf671f53.tar.bz2 |
Switch parsers to a model
Diffstat (limited to 'test/locate.js')
-rw-r--r-- | test/locate.js | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/test/locate.js b/test/locate.js deleted file mode 100644 index f9adcd7..0000000 --- a/test/locate.js +++ /dev/null @@ -1,34 +0,0 @@ -var path = require('path'); -var should = require('should'); - -var mock = require('./mock'); - -describe('Locate', function() { - it('should use root folder if no .gitbook', function() { - return mock.setupBook({ - 'README.md': '# Hello' - }) - .then(function(book) { - return book.prepareConfig() - .then(function() { - should(book.originalRoot).not.be.ok(); - }); - }); - }); - - it('should use resolve using book.js root property', function() { - return mock.setupBook({ - 'README.md': '# Hello', - 'docs/README.md': '# Hello Book', - 'book.json': { root: './docs' } - }) - .then(function(book) { - return book.prepareConfig() - .then(function() { - should(book.originalRoot).be.ok(); - book.root.should.equal(path.resolve(book.originalRoot, 'docs')); - }); - }); - }); - -}); |