I write ArgumentMatcher, and the gut comparisons come down to something like:
return A.value().equals(B.value()) && A.name().equals(B.name());
Unfortunately, when this does not go away, Mokito just tells me that it did not work. I want to add a custom message, for example, "Values โโdo not match" or "Names do not match" (of course, I would like to give more information, but so far I can not understand this simple case, in the future).
Before (before working with Mockito), I remember that they have two methods: one for checking compliance and one for generating an error message (although it was painful to write both methods, but now I skip the second method).
Any ideas how to do this? Any help is appreciated!
source
share