0.1.7 • Published 4 years ago
alpha-serializer-jest v0.1.7
alpha-serializer-jest
Snapshot serializer for jest test runner.
Install
npm install --save alpha-serializer-jest
Usage
Via global config
{
...
"jest": {
"snapshot-serializers": ["alpha-serializer-jest"]
}
}
Or in your tests code
const snapshotSerializer = require('alpha-serializer-jest');
expect.addSnapshotSerializer(snapshotSerializer);
// with custom normalizer
const {create} = require('alpha-serializer-jest');
expect.addSnapshotSerializer(create(normalizer));