title: Verify object attribute value with mockito
body: <p>I have a method call which I want to mock with mockito. To start with I have created and injected an instance of an object on which the method will be called. My aim is to verify one of the object in method call.</p>
  
  <p>Is there a way that mockito allows you to assert or verify the object and it's attributes when the mock method is called?</p>
  
  <p>example</p>
  
  <pre><code>Mockito.verify(mockedObject)
         .someMethodOnMockedObject(
                Mockito.&lt;SomeObjectAsArgument&gt;anyObject())
  </code></pre>
  
  <p>Instead of doing <code>anyObject()</code> i want to check that argument object contains some particular fields</p>
  
  <pre><code>Mockito.verify(mockedObject)
         .someMethodOnMockedObject(
                Mockito.&lt;SomeObjectAsArgument&gt;**compareWithThisObject()**)
  </code></pre>