### Question:
CancelServiceImpl implements CancelService { public boolean drawbackMoney(String money, String userId, HttpHeaders headers) { CancelServiceImpl.LOGGER.info("[Cancel Order Service][Draw Back Money] Draw back money..."); HttpEntity requestEntity = new HttpEntity(headers); ResponseEntity<Response> re = restTemplate.exchange( "http: HttpMethod.GET, requestEntity, Response.class); Response result = re.getBody(); return result.getStatus() == 1; }  @Override Response cancelOrder(String orderId, String loginId, HttpHeaders headers); boolean sendEmail(NotifyInfo notifyInfo, HttpHeaders headers); @Override Response calculateRefund(String orderId, HttpHeaders headers); boolean drawbackMoney(String money, String userId, HttpHeaders headers); Response<User> getAccount(String orderId, HttpHeaders headers);  }### Answer:
@Test public void testDrawbackMoney() { Response response = new Response<>(1, null, null); ResponseEntity<Response> re = new ResponseEntity<>(response, HttpStatus.OK); Mockito.when(restTemplate.exchange( "http: HttpMethod.GET, requestEntity, Response.class)).thenReturn(re); Boolean result = cancelServiceImpl.drawbackMoney("money", "userId", headers); Assert.assertTrue(result); }