@Test public void returnsNotFoundStatusWithNonHandledUrl() { StyxObjectStore<StyxObjectRecord<StyxService>> empty = new StyxObjectStore<>(); ServiceProviderHandler handler = new ServiceProviderHandler(empty); HttpRequest request = HttpRequest.get("/not/my/url").build(); HttpResponse response = Mono.from(handler.handle(request, requestContext())).block(); assertThat(response.status(), equalTo(NOT_FOUND)); }
@Override public Eventual<HttpResponse> handle(HttpRequest request, HttpInterceptor.Context context) { return urlRouter.handle(request, context); }
ServiceProviderHandler implements WebServiceHandler { @Override public Eventual<HttpResponse> handle(HttpRequest request, HttpInterceptor.Context context) { return urlRouter.handle(request, context); } }
ServiceProviderHandler implements WebServiceHandler { @Override public Eventual<HttpResponse> handle(HttpRequest request, HttpInterceptor.Context context) { return urlRouter.handle(request, context); } ServiceProviderHandler(StyxObjectStore<StyxObjectRecord<StyxService>> providerDatabase); }
ServiceProviderHandler implements WebServiceHandler { @Override public Eventual<HttpResponse> handle(HttpRequest request, HttpInterceptor.Context context) { return urlRouter.handle(request, context); } ServiceProviderHandler(StyxObjectStore<StyxObjectRecord<StyxService>> providerDatabase); @Override Eventual<HttpResponse> handle(HttpRequest request, HttpInterceptor.Context context); static ObjectMapper yamlMapper(); }
ServiceProviderHandler implements WebServiceHandler { @Override public Eventual<HttpResponse> handle(HttpRequest request, HttpInterceptor.Context context) { return urlRouter.handle(request, context); } ServiceProviderHandler(StyxObjectStore<StyxObjectRecord<StyxService>> providerDatabase); @Override Eventual<HttpResponse> handle(HttpRequest request, HttpInterceptor.Context context); static ObjectMapper yamlMapper();  }