HttpRequester { public <T> T get(URI url, Class<T> responseType) { return exchange(url, HttpMethod.GET, null, responseType); } HttpRequester();  HttpRequester(Properties securityProperties);   HttpRequester(Properties securityProperties, RestTemplate restTemplate); RestTemplate getRestTemplate(); T get(URI url, Class<T> responseType); T post(URI url, Object content, Class<T> responseType); Object executeWithResponseExtractor(URI url); static URI createURI(String baseUrl, String path, String... queryParams);  }
@Test public void get() throws Exception { requester = spy(new HttpRequester(securityProps, restTemplate)); String result = requester.get(uri, String.class); assertThat(result).isEqualTo("done"); verify(requester).exchange(uri, HttpMethod.GET, null, String.class); verifyHeaderIsUpdated(); }