### Question:
CorsHandler implements HttpHandler { @Override public void handleRequest(HttpServerExchange exchange) throws Exception { HeaderMap responseHeaders = exchange.getResponseHeaders(); responseHeaders.add(HttpString.tryFromString("Access-Control-Allow-Origin"), "*"); handler.handleRequest(exchange); } CorsHandler(HttpHandler handler); @Override void handleRequest(HttpServerExchange exchange);  }### Answer:
@Test void shouldDelegate() throws Exception { corsHandler.handleRequest(dummyExchange); assertTrue(testHandler.hasCalled()); }
@Test void shouldHaveCorsHeader() throws Exception { corsHandler.handleRequest(dummyExchange); String value = dummyExchange.getResponseHeaders().getFirst("Access-Control-Allow-Origin"); assertEquals("*", value); }