@Test
public void shouldReturnResponseCodeAndMessage() throws Throwable {

  when(mockHttpURLConnection.getResponseCode()).thenReturn(200);
  when(mockHttpURLConnection.getResponseMessage()).thenReturn("message");
  final HttpResponse httpResponse = httpFunction().apply(HTTP_GET_REQUEST).get();
  assertThat(httpResponse.getResponseCode(), is(200));
  assertThat(httpResponse.getResponseMessage(), is("message"));
  verify(mockHttpURLConnection).disconnect();
}