Open Thurnheer opened 10 months ago
This is a known problem. Unfortunately I am not sure that it is possible to solve.
When the mismatch happens, it throws an exception. That exception causes the expectation object for the other function to be destroyed, which makes it to be reported as never called.
Instead of reporting a missmatch in the function call it reports a missing function call Expected exhaust.update(Configuration{PERIOD, 5ms}) to be called once, actually never called.
See godbolt link to bug
The only difference in the left version to the right version of the code is line 154 where the right version has the correct expected value and the left version has a wrong value.
Expected behaviour on the left version would be call with wrong arguments