I use postman to check the json data schema returned from api.
I have a test that goes through a basic HTTP check and then ends with:
if (tv4.error){
console.log("Validation failed: ", tv4.error);
}
The error I am returning is hard to understand.
Verification failed: 12: 22: 41.316
Object: {}
message: "Invalid type: number (expected string)"
Name: "ValidationError"
Type: "Error"
But I need to know in which field the check was performed. How can I get this information? the npm page for tv4 suggests that the error message should be more visual.