toBeCalledWith failure output is weird with multiple mismatched calls #7884
Closed
Description
🐛 Bug Report
test("reproduce issue", () => {
let fn = jest.fn();
fn(1);
fn(2);
fn(3);
expect(fn).toBeCalledWith((5));
});
Expected behavior
Maybe a list of what is called with? Something like the failure output for the toBeCalled() matcher
Run npx envinfo --preset jest
Paste the results here:
Environment:
OS: macOS High Sierra 10.13.6
Node: 8.11.1
Yarn: 1.12.1
npm: 5.6.0
Watchman: 4.9.4
Xcode: Xcode 9.4.1 Build version 9F2000
Android Studio: 3.2 AI-181.5540.7.32.5056338