Searched refs:mockResponse (Results 1 – 5 of 5) sorted by relevance
/external/guice/extensions/servlet/test/com/google/inject/servlet/ |
D | ServletPipelineRequestDispatcherTest.java | 137 final HttpServletResponse mockResponse = createMock(HttpServletResponse.class); in testForwardToManagedServlet() local 146 expect(mockResponse.isCommitted()) in testForwardToManagedServlet() 149 mockResponse.resetBuffer(); in testForwardToManagedServlet() 181 replay(injector, binding, requestMock, mockResponse, mockBinding); in testForwardToManagedServlet() 190 dispatcher.forward(requestMock, mockResponse); in testForwardToManagedServlet() 194 verify(injector, requestMock, mockResponse, mockBinding); in testForwardToManagedServlet() 220 final HttpServletResponse mockResponse = createMock(HttpServletResponse.class); in forwardToManagedServletFailureOnCommittedBuffer() local 222 expect(mockResponse.isCommitted()) in forwardToManagedServletFailureOnCommittedBuffer() 253 replay(injector, binding, mockRequest, mockResponse, mockBinding); in forwardToManagedServletFailureOnCommittedBuffer() 264 dispatcher.forward(mockRequest, mockResponse); in forwardToManagedServletFailureOnCommittedBuffer() [all …]
|
/external/okhttp/okhttp-android-support/src/test/java/com/squareup/okhttp/internal/huc/ |
D | CacheAdapterTest.java | 252 private URL configureServer(MockResponse mockResponse) throws Exception { in configureServer() argument 253 server.enqueue(mockResponse); in configureServer() 258 private URL configureHttpsServer(MockResponse mockResponse) throws Exception { in configureHttpsServer() argument 260 server.enqueue(mockResponse); in configureHttpsServer()
|
D | ResponseCacheTest.java | 184 MockResponse mockResponse = new MockResponse() in assertCached() local 191 mockResponse.addHeader("Proxy-Authenticate: Basic realm=\"protected area\""); in assertCached() 193 mockResponse.addHeader("WWW-Authenticate: Basic realm=\"protected area\""); in assertCached() 195 server.enqueue(mockResponse); in assertCached() 231 MockResponse mockResponse = new MockResponse() in testResponseCaching() local 235 transferKind.setBody(mockResponse, "I love puppies but hate spiders", 1); in testResponseCaching() 236 server.enqueue(mockResponse); in testResponseCaching()
|
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/ |
D | CacheTest.java | 158 MockResponse mockResponse = new MockResponse() in assertCached() local 165 mockResponse.addHeader("Proxy-Authenticate: Basic realm=\"protected area\""); in assertCached() 167 mockResponse.addHeader("WWW-Authenticate: Basic realm=\"protected area\""); in assertCached() 170 mockResponse.setBody(""); // We forbid bodies for 204 and 205. in assertCached() 172 server.enqueue(mockResponse); in assertCached() 211 MockResponse mockResponse = new MockResponse() in testResponseCaching() local 215 transferKind.setBody(mockResponse, "I love puppies but hate spiders", 1); in testResponseCaching() 216 server.enqueue(mockResponse); in testResponseCaching() 500 MockResponse mockResponse = new MockResponse(); in testServerPrematureDisconnect() local 501 transferKind.setBody(mockResponse, "ABCDE\nFGHIJKLMNOPQRSTUVWXYZ", 16); in testServerPrematureDisconnect() [all …]
|
D | URLConnectionTest.java | 693 MockResponse mockResponse = new MockResponse().setBody("this response comes via a proxy"); in testConnectViaProxy() local 694 server.enqueue(mockResponse); in testConnectViaProxy() 766 MockResponse mockResponse = new MockResponse(); in contentDisagreesWithChunkedHeaderBodyTooLong() local 767 mockResponse.setChunkedBody("abc", 3); in contentDisagreesWithChunkedHeaderBodyTooLong() 768 Buffer buffer = mockResponse.getBody(); in contentDisagreesWithChunkedHeaderBodyTooLong() 770 mockResponse.setBody(buffer); in contentDisagreesWithChunkedHeaderBodyTooLong() 771 mockResponse.clearHeaders(); in contentDisagreesWithChunkedHeaderBodyTooLong() 772 mockResponse.addHeader("Transfer-encoding: chunked"); in contentDisagreesWithChunkedHeaderBodyTooLong() 774 server.enqueue(mockResponse); in contentDisagreesWithChunkedHeaderBodyTooLong() 780 MockResponse mockResponse = new MockResponse(); in contentDisagreesWithChunkedHeaderBodyTooShort() local [all …]
|