Open
Description
openedon Jul 21, 2024
Version
29.7.0 and 30.0.0-alpha.5
Steps to reproduce
- https://github.com/latin-1/jest-cr-snapshot-bugs
npm install
npx jest -u a.spec.js
CI=true npx jest a.spec.js
Expected behavior
It should work without errors.
Actual behavior
expect(received).toMatchSnapshot()
1`pshot name: `
New snapshot was not written. The update flag must be explicitly passed to write a new snapshot.
This is likely because this test is run in a continuous integration (CI) environment in which snapshots are not written by default.
Received: 1
1 | test("\r", () => {
> 2 | expect(1).toMatchSnapshot()
| ^
3 | });
4 |
at Object.toMatchSnapshot (a.spec.js:2:13)
Additional context
No response
Environment
System:
OS: Linux 6.9 Arch Linux
CPU: (16) x64 AMD Ryzen 7 6800U with Radeon Graphics
Binaries:
Node: 22.5.1 - ~/.proto/shims/node
Yarn: 4.3.1 - ~/.proto/shims/yarn
npm: 10.8.2 - ~/.proto/shims/npm
pnpm: 9.5.0 - ~/.proto/shims/pnpm
bun: 1.1.20 - ~/.proto/shims/bun
npmPackages:
jest: 29.7.0 => 29.7.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment