You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What steps will reproduce the problem?
1. Provide a REST service returning a typed JSON array like this one : [ {
"foo": "foo", "bar": "bar" }, { "foo": "hello", "bar": "world" } ]
2. Try to call this service in rest-assured, then map it on a List<Foo> (where
Foo contains foo and bar fields) :
List<Foo> myList = expect().statusCode(200).when().get("/foos").as(List.class);
3. Since we have reified generics in Java, rest-assured cannot predict the
parameterized type of the List and then, will map the return type in a
List<Map> instead of a List<Foo>
Idea would be to provide a GSON-like approach with something looking like
TypeToken.
Discussion started on google group here :
https://groups.google.com/forum/#!topic/rest-assured/0GIQQfzC_6c
Original issue reported on code.google.com by fcamb...@gmail.com on 10 Jan 2012 at 8:08
The text was updated successfully, but these errors were encountered:
Original issue reported on code.google.com by
fcamb...@gmail.com
on 10 Jan 2012 at 8:08The text was updated successfully, but these errors were encountered: