mockcpp icon indicating copy to clipboard operation
mockcpp copied to clipboard

Is there a way to monitor the function calls without changing the original behavior?(有方法可以只监控函数调用次数,不改变原函数的行为吗)

Open DaysChan opened this issue 1 year ago • 2 comments

虽然函数实现很简单,我也不希望复制一份函数代码去调用invoke。

DaysChan avatar Jul 27 '24 10:07 DaysChan

可以变通使用, 在桩函数中 先拆桩, 然后调用原函数, 再重新打桩

fish2bird avatar Aug 26 '24 03:08 fish2bird

可以变通使用, 在桩函数中 先拆桩, 然后调用原函数, 再重新打桩

https://github.com/sinojelly/mockcpp/issues/30 这个issue里也有提到,无法单独取消某个mock,所以是要先用verify全部拆桩,最后再重新全部打桩是吧? 我下次试试 :)

DaysChan avatar Oct 12 '24 02:10 DaysChan