You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I think there is an often case when we need to set expected times that concrete controller method will be executed during the test. Currently, <method>AfterCounter allows only to get the current value of calls to the mocked method, which is useless in table tests and lead to potential logical errors to pass the test.
There is a convenient method Times(N) in gomock. Could you add a similar one?
The text was updated successfully, but these errors were encountered:
CyganFx
changed the title
Proposal: allow expected counter for concrete controller's method
Allow expected counter for concrete controller's method
Nov 30, 2022
@CyganFx hi, thanks for issue. In this case we could use <method>AfterCounter but i agree that it is not very convenient way when you write table test and want to chain expectations. Feature could be added in pr above
Hi, I think there is an often case when we need to set expected times that concrete controller method will be executed during the test. Currently,
<method>AfterCounter
allows only to get the current value of calls to the mocked method, which is useless in table tests and lead to potential logical errors to pass the test.There is a convenient method
Times(N)
in gomock. Could you add a similar one?The text was updated successfully, but these errors were encountered: