Hi All,
I am been facing the issue not sure how to fix it.
The postman returns 200 code for post method.
however with rest assured it returns 404 not found error,
String body = "{\n" +
" \"id\": \"4\",\n" +
" \"name\": \"danka\",\n" +
" \"adress\": {\n" +
" \"city\": \"Calcutta\",\n" +
" \"country\": \"India\"\n" +
" }\n" +
" }";
System.out.println(body);
given().contentType("application/json")
.body(body)
.when().post("http://127.0.0.1:8080/customers").then().log().all()
.statusCode(200);get request is working fine.
can I anyone suggest some solution?