diff options
author | Samy Pessé <samypesse@gmail.com> | 2016-02-17 15:18:49 +0100 |
---|---|---|
committer | Samy Pessé <samypesse@gmail.com> | 2016-02-17 15:18:49 +0100 |
commit | 40cdc285b613949347f2909d8f7027fc51b0db7f (patch) | |
tree | 2819da32f7b619e11267a28a910159c6f1e74859 /test/template.js | |
parent | 46f017e68bd919c365311a78d02252a451afdc04 (diff) | |
download | gitbook-40cdc285b613949347f2909d8f7027fc51b0db7f.zip gitbook-40cdc285b613949347f2909d8f7027fc51b0db7f.tar.gz gitbook-40cdc285b613949347f2909d8f7027fc51b0db7f.tar.bz2 |
Don't build context in templating engine
Diffstat (limited to 'test/template.js')
-rw-r--r-- | test/template.js | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/test/template.js b/test/template.js index a76fe93..6eb2278 100644 --- a/test/template.js +++ b/test/template.js @@ -1,5 +1,4 @@ var mock = require('./mock'); -var pkg = require('../package.json'); var Output = require('../lib/output/base'); describe('Template', function() { @@ -19,8 +18,8 @@ describe('Template', function() { }); it('should render with variable', function() { - return output.template.renderString('Version is {{ gitbook.version }}') - .should.be.fulfilledWith('Version is '+pkg.version); + return output.template.renderString('Hello {{ world }}', { world: 'World'}) + .should.be.fulfilledWith('Hello World'); }); }); |