HttpServletAdapter extends HttpServerAdapter<HttpServletRequest, HttpServletResponse> { @Override public String path(HttpServletRequest request) { return request.getRequestURI(); }  HttpServletResponse adaptResponse(HttpServletRequest req, HttpServletResponse resp); @Override boolean parseClientIpAndPort(HttpServletRequest req, Span span); @Override String method(HttpServletRequest request); @Override String path(HttpServletRequest request); @Override String url(HttpServletRequest request); @Override String requestHeader(HttpServletRequest request, String name); @Override String methodFromResponse(HttpServletResponse response); @Override String route(HttpServletResponse response); @Override @Nullable Integer statusCode(HttpServletResponse response); @Override int statusCodeAsInt(HttpServletResponse response);  }
@Test public void path_doesntCrashOnNullUrl() { assertThat(adapter.path(request)) .isNull(); }
@Test public void path_getRequestURI() { when(request.getRequestURI()).thenReturn("/bar"); assertThat(adapter.path(request)) .isEqualTo("/bar"); }