diff options
Diffstat (limited to 'test/plugins.js')
-rw-r--r-- | test/plugins.js | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/test/plugins.js b/test/plugins.js index 2351537..c7d1f90 100644 --- a/test/plugins.js +++ b/test/plugins.js @@ -48,19 +48,33 @@ describe('Plugins', function () { assert(plugin.isValid()); }); - it('should return a valid list of resources', function(done) { + it('should return a valid list of resources (website)', function(done) { qdone( - plugin.getResources() + plugin.getResources("website") .then(function(resources) { assert.equal(resources["js"].length, 1); }), done); }); - it('should extend books plugins', function() { - var resources = books[0].plugins.resources; + it('should return a valid list of resources (ebook)', function(done) { + qdone( + plugin.getResources("ebook") + .then(function(resources) { + assert.equal(resources["css"].length, 1); + }), + done); + }); + + it('should extend books plugins (website)', function() { + var resources = books[0].plugins.resources("website"); assert.equal(resources["js"].length, 1); }); + + it('should extend books plugins (ebook)', function() { + var resources = books[0].plugins.resources("ebook"); + assert.equal(resources["css"].length, 1); + }); }); describe('filters', function() { |