Take a look at this picture. what is going on with Mockito verifying Argument ?
I want to verify that view is invoked with the argument factory.
@Test
public void shouldInitializeTheDriverWithTheRequestFactory() {
CVProxy proxy = context.create(CVProxy.class);
workflow.initialize();
verify(view).initializeWithRequestFactory(factory);
verify(view).editWithEditor(proxy, context);
}
However I got this error which is weird ?!
Argument(s) are different! Wanted:
view.initializeWithRequestFactory(
com.google.web.bindery.requestfactory.vm.InProcessRequestFactory@13c6a22
);
-> at CreatingNewCVWorkflowTest.shouldInitializeTheDriverWithTheRequestFactory(CreatingNewCVWorkflowTest.java:53)
Actual invocation has different arguments:
view.initializeWithRequestFactory(
com.google.web.bindery.requestfactory.vm.InProcessRequestFactory@13c6a22
);
as you can the arguments are IDENTICAL.