Is there a way to accept any number of arguments when mocking a method?
For example, if I want to mock these two methods:
foo(String s); foo(String s, int i);
Bye, in my test:
myMockedClass.foo(_) >> x myMockedClass.foo(_, _) >> x
Is there a way to fool both at once? Sort of:
myMockedClass.foo(*) >> x
(this does not work)
source share