### Question:
CurrencyExchangeController { @GetMapping("/currency-exchange/from/{from}/to/{to}") public ExchangeValue retrieveExchangeValue(@PathVariable String from, @PathVariable String to, @RequestHeader Map<String, String> headers) { printAllHeaders(headers); ExchangeValue exchangeValue = repository.findByFromAndTo(from, to); LOGGER.info("{} {} {}", from, to, exchangeValue); if (exchangeValue == null) { throw new RuntimeException("Unable to find data to convert " + from + " to " + to); } exchangeValue.setExchangeEnvironmentInfo(instanceInformationService.retrieveInstanceInfo()); return exchangeValue; }  @GetMapping("/") String imHealthy(); @GetMapping("/currency-exchange/from/{from}/to/{to}") ExchangeValue retrieveExchangeValue(@PathVariable String from, @PathVariable String to,
			@RequestHeader Map<String, String> headers);  }### Answer:
@Test public void retrieveExchangeValue() throws Exception { Mockito.when(repository.findByFromAndTo("EUR", "INR")).thenReturn(new ExchangeValue(Long.getLong("1"), "EUR", "INR", BigDecimal.valueOf(80.00))); mvc.perform(get("/currency-exchange/from/EUR/to/INR")).andExpect(status().isOk()); }