beater-snapshot
This package is alpha version. You can use Jest.
A snapshot testing library for beater.
Installation
$ npm install --save-dev beater-snapshot
Usage
// test.jsconst init = ; const matchSnapshot = ; // optionsconst actual = your: 'test target' ;; console;
$ node test.js # Error: no snapshot
$ UPDATE_SNAPSHOT=true node test.js # update snapshot
OK
$ ls __snapshots__/
snapshot_file_name.json # snapshot files
$ cat __snapshots__/snapshot_file_name.json
{
"your": "test target"
}
$ node test.js # Success
OK
Options
See: test/helpers.ts