title: How to verify that array contains object with rest assured?
body: <p>For example, I have JSON in response:</p>
  
  <pre><code>[{"id":1,"name":"text"},{"id":2,"name":"text"}]}
  </code></pre>
  
  <p>I want to verify if a response contains a custom object. For example: </p>
  
  <pre><code>Person(id=1, name=text)
  </code></pre>
  
  <p>I found solution:</p>
  
  <pre><code>Person[] persons = response.as(Person[].class);
  assertThat(person, IsArrayContaining.hasItemInArray(expectedPerson));
  </code></pre>
  
  <p>I want to have something like this:</p>
  
  <pre><code>response.then().assertThat().body(IsArrayContaining.hasItemInArray(object));
  </code></pre>
  
  <p>Is there any solution for this?<br>
  Thanks in advance for your help!</p>