HttpURLConnectionHttpChannel implements HttpChannel { public void setContentType(String value) throws IOException { setHeader("Content-Type", value); } HttpURLConnectionHttpChannel(HttpURLConnection con, MethodType methodType); void setSocketTimeout(int timeout); void setConnectionTimeout(int timeout); void setHeader(String name, String value); void addHeader(String name, String value); void setContentType(String value); void setAccept(String value); void writeEntityWith(HttpEntityWriter httpEntityWriter); Response send();  }
@Test public void setContentTypeShouldSetItIntoHttpUrlConnection() throws IOException { toTest.setContentType("value"); verify(httpURLConnection).setRequestProperty("Content-Type", "value"); }