{"action":"created","issue":{"url":"https://api.github.com/repos/jayway/rest-assured/issues/512","labels_url":"https://api.github.com/repos/jayway/rest-assured/issues/512/labels{/name}","comments_url":"https://api.github.com/repos/jayway/rest-assured/issues/512/comments","events_url":"https://api.github.com/repos/jayway/rest-assured/issues/512/events","html_url":"https://github.com/jayway/rest-assured/issues/512","id":96274510,"number":512,"title":"Output format when comparing entire JSON bodies is hard to read","user":{"login":"johanhaleby","id":187029,"avatar_url":"https://avatars.githubusercontent.com/u/187029?v=3","gravatar_id":"","url":"https://api.github.com/users/johanhaleby","html_url":"https://github.com/johanhaleby","followers_url":"https://api.github.com/users/johanhaleby/followers","following_url":"https://api.github.com/users/johanhaleby/following{/other_user}","gists_url":"https://api.github.com/users/johanhaleby/gists{/gist_id}","starred_url":"https://api.github.com/users/johanhaleby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johanhaleby/subscriptions","organizations_url":"https://api.github.com/users/johanhaleby/orgs","repos_url":"https://api.github.com/users/johanhaleby/repos","events_url":"https://api.github.com/users/johanhaleby/events{/privacy}","received_events_url":"https://api.github.com/users/johanhaleby/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/jayway/rest-assured/labels/bug","name":"bug","color":"FFFFFF"},{"url":"https://api.github.com/repos/jayway/rest-assured/labels/imported","name":"imported","color":"FFFFFF"},{"url":"https://api.github.com/repos/jayway/rest-assured/labels/Priority-Medium","name":"Priority-Medium","color":"ededed"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-21T09:45:42Z","updated_at":"2015-07-21T09:45:43Z","closed_at":null,"body":"_From [mikeycmc...@gmail.com](https://code.google.com/u/108668612804261323496/) on September 29, 2014 15:07:39_\n\nWhat steps will reproduce the problem? 1. Create a test where you compare the entire body of a response that is JSON\r\n2. Look at the output in IntelliJ\r\n3. Try to determine which field is wrong when there is a big payload What is the expected output? What do you see instead? We would expect it to be easy to see the exact part of the payload that differs. When debugging, the specific error seems to be part of the Hamcrest mismatch description, but it gets discarded/is ignored by RESTAssured, meaning we see something like this:\r\n\r\nExpected: \"{\\\"errors\\\":[{\\\"code\\\":503,\\\"message\\\":\\\"Internal database errors\\\"}]}\"\r\n  Actual: {\"errors\":[{\"code\":503,\"message\":\"Internal database error\"}]}\r\n\r\nThis isn't too bad for a small payload, but when you have bigger response bodies with HAL etc, you end up needing to paste into an editor, remove the backspaces etc just to try to determine what is up. What version of the product are you using? On what operating system? 2.3.3 - OSX 10.9.4 Please provide any additional information below. We are comparing the body by providing a fixture, such as\r\n\r\n                body(matchesJsonFixture(\"fixtures/database_exception_error_response.json\")).\r\n\r\n\r\nmatchesJsonFixture looks like this:\r\n    public static SameJSONAs<? super String> matchesJsonFixture(String fixtureLocation) {\r\n        String fixtureContent = fixture(fixtureLocation);\r\n        String normalisedJson = new JsonParser().parse(fixtureContent).toString();\r\n        return sameJSONAs(normalisedJson);\r\n    }\r\n\r\nBut I don't think this is the problem. Thanks\n\n_Original issue: http://code.google.com/p/rest-assured/issues/detail?id=357_"},"comment":{"url":"https://api.github.com/repos/jayway/rest-assured/issues/comments/123243880","html_url":"https://github.com/jayway/rest-assured/issues/512#issuecomment-123243880","issue_url":"https://api.github.com/repos/jayway/rest-assured/issues/512","id":123243880,"user":{"login":"johanhaleby","id":187029,"avatar_url":"https://avatars.githubusercontent.com/u/187029?v=3","gravatar_id":"","url":"https://api.github.com/users/johanhaleby","html_url":"https://github.com/johanhaleby","followers_url":"https://api.github.com/users/johanhaleby/followers","following_url":"https://api.github.com/users/johanhaleby/following{/other_user}","gists_url":"https://api.github.com/users/johanhaleby/gists{/gist_id}","starred_url":"https://api.github.com/users/johanhaleby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johanhaleby/subscriptions","organizations_url":"https://api.github.com/users/johanhaleby/orgs","repos_url":"https://api.github.com/users/johanhaleby/repos","events_url":"https://api.github.com/users/johanhaleby/events{/privacy}","received_events_url":"https://api.github.com/users/johanhaleby/received_events","type":"User","site_admin":false},"created_at":"2015-07-21T09:45:43Z","updated_at":"2015-07-21T09:45:43Z","body":"_From [johan.ha...@gmail.com](https://code.google.com/u/105676376875942041029/) on September 30, 2014 23:43:33_\n\nDo you have any suggestions for how to solve this in a generic way?  I cannot think of a generic solution for this on top of my head."}}