I am writing JUnit Test case for a class which has two methods methodA,methodB. I would like to mock the call to the methodB from methodA in my test case I am using spy on
I ran into this yesterday, for spies is best to do doReturn(X).when(spy).method(any())