1 | # JsDiff with console output [![Dependency Status](https://david-dm.org/kevgo/jsdiff-console.svg)](https://david-dm.org/kevgo/jsdiff-console)
|
2 |
|
3 | This is a very simple helper method for tests that require
|
4 | diffing JSON data.
|
5 | It uses the excellent [jsdiff](https://github.com/kpdecker/jsdiff) module.
|
6 |
|
7 | Using it in your tests is super easy:
|
8 |
|
9 | ```livescript
|
10 | require! 'diffjs-console'
|
11 |
|
12 | diffjs-console actual-json, expected-json
|
13 | ```
|
14 |
|
15 | You can provide an async return method as the third argument
|
16 | to have your tests automatically fail if the data structures are different.
|
17 |
|
18 | ```livescript
|
19 | diffjs-console actual-json, expected-json, done
|
20 | ```
|