I've start moving some of the code from MPMC to MockInternal and found
this weird issue. If I change
Object invokeMethod(Class sender, Object receiver, String
methodName, Object[] arguments, boolean isCallToSuper, boolean
fromInsideClass) {
doInternal(controller) {
adaptee.invokeMethod(receiver, methodName, arguments)
} {
return mock.invokeMockMethod(sender, receiver, methodName,
arguments)
}
}
to
Object invokeMethod(Class sender, Object receiver, String
methodName, Object[] arguments, boolean isCallToSuper, boolean
fromInsideClass) {
return mock.invokeMockMethod(sender, receiver, methodName,
arguments)
}
I am having the testPassAMockObjectToAnotherButNotCalled that start to
fail. Somehow in the line '
mock1.is(mock2).returns(true)' mock2 is
seen as a recorder.
There a bit of magic happening here. Any idea how ?
On Mar 2, 6:27 pm, Julien Gagnet <
julien.gag...@gmail.com> wrote:
> I think I'll try to do something similar to the hashcode, tostring...
> and only fail if some expectations has been setup on that particular
> method. I hope we are not in a rush for 0.7 cause I might take my time
> to do it but looking forward to it.
>
> 2009/3/2 Johnny <
johnnyjia...@gmail.com>: