Laravel - HTTP Tests - Assert Json Validation Errors

Assert that the response has the given JSON validation errors for the given keys. This method should be used when asserting against responses where the validation errors are returned as a JSON structure instead of being flashed to the session:

    $response->assertJsonValidationErrors(array $data);
The more generic assertInvalid method may be used to assert that a response has validation errors returned as JSON or that errors were flashed to session storage.