Closed jyteshpunjwani closed 4 years ago
What exactly do you expect? What would be in the JSON? How would it look like? Could you give an example?
@jyteshpunjwani Could you please respond to my question? Otherwise I can't really do anything.
I don't know about the original poster however I would like to see the differences written out in the exclusion JSON format so that it would be possible to just use the files as a starting point for an exclusion on the next run.
The CompareResult has a Method: getDifferences(), that gives you a Collection
ObjectMapper objectMapper = new ObjectMapper(); String exclusionJson = "exclusions: " + objectMapper.writeValueAsString(compareResult.getDifferences());
Would that be enough?
I could add that as a method to CompareResultImpl, but I'm a little unsure, since pulling in Jackson might cause problems with other projects that already use a different version of Jackson etc. And just for this simple feature, I'm not sure I want to pull that in.
I created a simple CompareResult.getDifferencesJson()-method. It is included in release 1.1.47, which should land in maven central in a few hours...
That all makes sense (including not introducing Jackson). Thanks for looking at this...
Hey, i was wondering if we can get difference output in json instead of pdf so i can just grab the difference area from JSON output?