Home | History | Annotate | Download | only in integration

Lines Matching refs:response

60         public Response response;
67 public Response serve(IHTTPSession session) {
68 return response;
72 protected boolean useGzipWhenAccepted(Response r) {
84 testServer.response = NanoHTTPD.newFixedLengthResponse("This is a test");
87 HttpResponse response = httpclient.execute(request);
88 Header contentEncoding = response.getFirstHeader("content-encoding");
96 testServer.response = NanoHTTPD.newChunkedResponse(NanoHTTPD.Response.Status.OK, "text/plain", data);
99 HttpResponse response = httpclient.execute(request);
100 Header contentEncoding = response.getFirstHeader("content-encoding");
107 testServer.response = NanoHTTPD.newFixedLengthResponse("This is a test");
110 HttpResponse response = httpclient.execute(request);
111 Header contentEncoding = response.getFirstHeader("content-encoding");
118 testServer.response = NanoHTTPD.newFixedLengthResponse("This is a test");
121 HttpResponse response = httpclient.execute(request);
122 Header contentLength = response.getFirstHeader("content-length");
123 assertNull("Content-Length should not be set when gzipping response", contentLength);
128 testServer.response = NanoHTTPD.newFixedLengthResponse("This is a test");
131 HttpResponse response = new DecompressingHttpClient(httpclient).execute(request);
132 assertEquals("This is a test", EntityUtils.toString(response.getEntity()));
138 testServer.response = NanoHTTPD.newChunkedResponse(NanoHTTPD.Response.Status.OK, "text/plain", data);
141 HttpResponse response = new DecompressingHttpClient(httpclient).execute(request);
142 assertEquals("This is a test", EntityUtils.toString(response.getEntity()));
147 testServer.response = NanoHTTPD.newFixedLengthResponse("This is a test");
149 HttpResponse response = httpclient.execute(request);
150 Header contentEncoding = response.getFirstHeader("content-encoding");
152 assertEquals("This is a test", EntityUtils.toString(response.getEntity()));
157 testServer.response = NanoHTTPD.newFixedLengthResponse("This is a test");
158 testServer.response.addHeader("Content-Length", "" + ("This is a test".getBytes("UTF-8").length));
161 HttpResponse response = httpclient.execute(request);
162 Header contentEncoding = response.getFirstHeader("content-encoding");
164 assertEquals("This is a test", EntityUtils.toString(response.getEntity()));