Function assertSnapshot
- assert
Snapshot <T>(context, actual, options): Promise<void> Type Parameters
Parameters
- context: TestContext
The test context
- actual: T
The actual value to compare
- options: SnapshotOptions<T>
The options
Returns Promise<void>
- context: TestContext
- assert
Snapshot <T>(context, actual, message?): Promise<void> Make an assertion that
actualmatches a snapshot. If the snapshot andactualdo not match, then throw.Type parameter can be specified to ensure values under comparison have the same type.
Type Parameters
Parameters
- context: TestContext
The test context
- actual: T
The actual value to compare
Optionalmessage: stringThe optional assertion message
Returns Promise<void>
- context: TestContext
Make an assertion that
actualmatches a snapshot. If the snapshot andactualdo not match, then throw.Type parameter can be specified to ensure values under comparison have the same type.