We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 922a4f0 + 1f3bf92 commit 45e5f10Copy full SHA for 45e5f10
guide/snapshot.md
@@ -236,8 +236,6 @@ test('toThrowErrorMatchingSnapshot', () => {
236
})
237
```
238
239
-“toThrowErrorMatchingSnapshot”和“toThrow ErrorMatchingInlineSnapshot”的默认“错误”快照不同`
240
-
241
在 Jest 中,快照将是:
242
243
```console
@@ -260,7 +258,7 @@ test('snapshot', () => {
260
258
261
259
expect(new Error('error')).toMatchInlineSnapshot('[Error: error]')
262
263
- // Jest snapshots `Error.message` for `Error` instance
+ // Jest 在 `Error` 实例上记录 `Error.message` 快照
264
expect(() => {
265
throw new Error('error')
266
}).toThrowErrorMatchingInlineSnapshot('"error"')
0 commit comments