title: Mockito when checking for specific object property value
body: <p>I have the following in a working test:</p>
  
  <pre><code>when(client.callApi(anyString(), isA(Office.class))).thenReturn(responseOne);
  </code></pre>
  
  <p>Note that client is a Mock of class Client.</p>
  
  <p>I want to change "isA(Office.class)" to tell it to match where the "id" property of an Office instance is "123L". How can I specify that I want a specific argument value in the method of a mocked object?</p>
  
  <p>Edit: Not a duplicate because I'm trying to use it on a "when" and the linked question (and other resources I've found) are using ArgumentCaptor and ArgumentMatcher on "verify" and "assert". I'm thinking I can't actually do what I'm trying and will try out another way. Of course, I'm willing to be shown otherwise.</p>