I have been playing around testing an api I've looked for ID 24 in my test and my actual and expected are the same I'm assuming I'm using the incorrect syntax where I have .body what should I put in place instead?
@Test
public void test_get_userid() {
given().
when().
get("http://bpdts-test-app-v2.herokuapp.com/user/24").
then().
assertThat().
statusCode(200).
and().
contentType(ContentType.JSON).
and().
body("id", equalTo("24"));
}
java.lang.AssertionError: 1 expectation failed.
JSON path id doesn't match.
Expected: 24
Actual: 24