Skip to content

Commit 93e284e

Browse files
committed
chore: add chai and dirty-chai for better test assertions
1 parent c02b05f commit 93e284e

File tree

4 files changed

+70
-1
lines changed

4 files changed

+70
-1
lines changed

package-lock.json

+60-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+2
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@
3434
"babel-loader": "^5.0.0",
3535
"babel-runtime": "^5.1.10",
3636
"benchmark": "~1.0",
37+
"chai": "^4.2.0",
38+
"dirty-chai": "^2.0.1",
3739
"dtslint": "^0.5.5",
3840
"dustjs-linkedin": "^2.0.2",
3941
"eco": "~1.1.0-rc-3",

spec/env/node.js

+6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
require('./common');
22

3+
var chai = require('chai');
4+
var dirtyChai = require('dirty-chai');
5+
6+
chai.use(dirtyChai);
7+
global.expect = chai.expect;
8+
39
global.Handlebars = require('../../lib');
410

511
global.CompilerContext = {

spec/index.html

+2
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020
}
2121
</script>
2222
<script src="/node_modules/mocha/mocha.js"></script>
23+
<script src="/node_modules/chai/chai.js"></script>
24+
<script src="/node_modules/dirty-chai/lib/dirty-chai.js"></script>
2325
<script>
2426
mocha.setup('bdd');
2527
</script>

0 commit comments

Comments
 (0)