@Test public void tick() { webTestClient.get().uri("/shorteners/health/ticks").accept(MediaType.APPLICATION_JSON).exchange() .expectStatus().isOk() .expectHeader().contentType(MediaType.APPLICATION_JSON) .expectBody(); }
Mono<ServerResponse> tick(ServerRequest req) { log.info("tick() ->"); return ServerResponse.ok() .contentType(MediaType.APPLICATION_JSON) .body(Mono.just("Tick"), String.class); }
ShortenerHandler implements HttpHandler { Mono<ServerResponse> tick(ServerRequest req) { log.info("tick() ->"); return ServerResponse.ok() .contentType(MediaType.APPLICATION_JSON) .body(Mono.just("Tick"), String.class); } }
ShortenerHandler implements HttpHandler { Mono<ServerResponse> tick(ServerRequest req) { log.info("tick() ->"); return ServerResponse.ok() .contentType(MediaType.APPLICATION_JSON) .body(Mono.just("Tick"), String.class); } ShortenerHandler(ShortenerService shortenerService, ShortenerQuery shortenerQuery); }
ShortenerHandler implements HttpHandler { Mono<ServerResponse> tick(ServerRequest req) { log.info("tick() ->"); return ServerResponse.ok() .contentType(MediaType.APPLICATION_JSON) .body(Mono.just("Tick"), String.class); } ShortenerHandler(ShortenerService shortenerService, ShortenerQuery shortenerQuery); @Override RouterFunction<ServerResponse> route(); }
ShortenerHandler implements HttpHandler { Mono<ServerResponse> tick(ServerRequest req) { log.info("tick() ->"); return ServerResponse.ok() .contentType(MediaType.APPLICATION_JSON) .body(Mono.just("Tick"), String.class); } ShortenerHandler(ShortenerService shortenerService, ShortenerQuery shortenerQuery); @Override RouterFunction<ServerResponse> route();  }