Skip to content

Commit

Permalink
Tweak parametrized emptyList
Browse files Browse the repository at this point in the history
  • Loading branch information
Bogdan Langendorf committed Jun 17, 2014
1 parent d61ce98 commit ffedbb4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/test/java/retromock/MockClientTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import retrofit.RestAdapter;
import retrofit.client.Request;
import retrofit.client.Response;
import retrofit.client.Header;
import retrofit.http.Body;
import retrofit.http.GET;
import retrofit.http.Headers;
Expand All @@ -28,13 +29,13 @@ static interface TestCase {

@Test
public void testARequest() throws Exception {
Response getResponse = new Response("", 200, "", Collections.EMPTY_LIST, new TypedByteArray("text/plain", "\"Hello, World\"".getBytes()));
Response getResponse = new Response("", 200, "", Collections.<Header>emptyList(), new TypedByteArray("text/plain", "\"Hello, World\"".getBytes()));
final MockClient.ResponseFactory responseFactory = new MockClient.ResponseFactory() {
@Override
public Response createFrom(Request request) throws IOException {
ByteArrayOutputStream os = new ByteArrayOutputStream();
request.getBody().writeTo(os);
return new Response("", 200, "", Collections.EMPTY_LIST, new TypedByteArray("text/plain", os.toByteArray()));
return new Response("", 200, "", Collections.<Header>emptyList(), new TypedByteArray("text/plain", os.toByteArray()));
}
};
MockClient.Provider client = MockClient.when()
Expand Down

0 comments on commit ffedbb4

Please sign in to comment.