users@jersey.java.net

[Jersey] Jersey Test Framework returned entity strangeness

From: Mike Summers <msummers57_at_gmail.com>
Date: Mon, 6 Aug 2012 11:24:47 -0500

I have a Jersey Test Framework Test that receives an object from the server
that contains a List<String>.

The List is returned as null without any errors on the part of the server
or the client, however if I look at the ClientResponse entity as a String I
can see the correctly formatted JSON returned by the server. On the server
I've tried return both the object and the object embedded in a JResponse
entity, no difference in the result.

I've also written a JUnit test using Jersey Client to run against the live
server and it has no problem receiving the server's object decoding a valid
List<String>.

Has anyone seen this before? Suggestions?

        <dependency>
        <groupId>com.sun.jersey.jersey-test-framework</groupId>
        <artifactId>jersey-test-framework-grizzly</artifactId>
        <version>1.12</version>
        <scope>test</scope>
        </dependency>

Thanks-- Mike