assertEquals(requestMethod, shouldOverride ? requestMethod : null,
request.getHeaders().get(MethodOverride.HEADER));
}
public void testInterceptMaxLength() throws IOException {
HttpTransport transport = new MockHttpTransport();
GenericUrl url = new GenericUrl(HttpTesting.SIMPLE_URL);
url.set("a", "foo");
HttpRequest request =
transport.createRequestFactory().buildGetRequest(HttpTesting.SIMPLE_GENERIC_URL);
new MethodOverride().intercept(request);
assertEquals(HttpMethods.GET, request.getRequestMethod());
assertNull(request.getHeaders().get(MethodOverride.HEADER));
assertNull(request.getContent());
char[] arr = new char[MethodOverride.MAX_URL_LENGTH];