README
jest-dify-snapshot
Usage
1. Install
npm i --save-dev jest-dify-snapshot
# or if you are using yarn
yarn --save-dev jest-dify-snapshot
2. Extend Jest expect
const { toMatchImageSnapshot } = require('jest-dify-snapshot');
expect.extend({ toMatchImageSnapshot });
expect(...).toMatchImageSnapshot()
3. Use it('should match image snapshot', () => {
// ...
expect(img).toMatchImageSnapshot();
});