1 | karma-chai-sinon
|
2 | ==========
|
3 |
|
4 | [Chai](http://chaijs.com) + [Sinon-Chai](http://chaijs.com/plugins/sinon-chai) + [Sinon](http://sinonjs.org/) for [Karma](http://karma-runner.github.io)
|
5 |
|
6 | *What makes this plugin different from `karma-sinon-chai`?*
|
7 | * It allows you to use either the latest versions of sinon, chai and sinon-chai or the specific versions your project already uses.
|
8 | * Enforces the use of stable versions of Node and Karma.
|
9 | * It uses `peerDependencies` only.
|
10 | * No `bower` dependency.
|
11 |
|
12 | [![NPM](https://nodei.co/npm/karma-chai-sinon.png?downloads=true)](https://npmjs.org/package/karma-chai-sinon)
|
13 |
|
14 | Installation
|
15 | ------------
|
16 |
|
17 | Install the plugin from npm:
|
18 |
|
19 | ```sh
|
20 | $ npm install karma-chai-sinon --save-dev
|
21 | ```
|
22 |
|
23 | Install the plugin from Github:
|
24 |
|
25 | ```sh
|
26 | $ npm install 'git://github.com/tubalmartin/karma-chai-sinon.git' --save-dev
|
27 | ```
|
28 |
|
29 | Add `chai-sinon` to the `frameworks` key in your Karma configuration:
|
30 |
|
31 | ```js
|
32 | module.exports = function(config) {
|
33 | config.set({
|
34 |
|
35 | // frameworks to use
|
36 | frameworks: ['mocha', 'chai-sinon']
|
37 |
|
38 | // ...
|
39 | ```
|
40 |
|
41 | License
|
42 | -------
|
43 |
|
44 | The MIT License (MIT)
|