This repository was archived by the owner on Dec 19, 2023. It is now read-only.

Description
In response to jmisur for issue #183. I've created a sanitized version of my test code. It should be complete and being able to help you pinpoint where it goes wrong.
Original post: "We handle our JSON responses in a generic we and use a RESTResponse object for it. Code: return RestResponse.create(, HttpStatus.CREATED); RestResponse generates two JSON objects, meta{} and data{}. Meta contains the RestMetadata object. Its has a fixed number of fields AND SARD shows info for those field. The data object however changes all the time depending on what object we create and hence the fields in it. The only output we get from SARD is data (Path) Var (Type) false (optional) and a generic description. It is somehow possible to show the fields of . Thats essential for us."
We've done some more digging. Wrt to file RestResponse. It looks as if Spring Auto Rest Docs doesn't like generics or doesn't go/dig deep enough. private T m_data; holds the data (using generics). Replacing this by Object and still using generics doesn't solve the problem. If however we create a RestResponse class for a specific domain or JsonObject it of course works. For example see the file RestResponseGoodFaultExample.txt
We use 'spring-auto-restdocs-core', version: '1.0.10' and Spring 4.3.7.RELEASE'
If you need more info please feel free to ask.
RestDocumentsExample.zip