SpringWebfluxClientRequestTagAdapter extends HttpTagAndSpanNamingAdapter<ClientRequest, ClientResponse> { @Override public @Nullable String getRequestPath(@Nullable ClientRequest request) { if (request == null || request.url() == null) { return null; } return request.url().getPath(); }  static SpringWebfluxClientRequestTagAdapter getDefaultInstance(); @Override @Nullable String getRequestUrl(@Nullable ClientRequest request); @Override @Nullable Integer getResponseHttpStatus(@Nullable ClientResponse response); @Override @Nullable String getRequestHttpMethod(@Nullable ClientRequest request); @Override @Nullable String getRequestPath(@Nullable ClientRequest request); @Override @Nullable String getRequestUriPathTemplate(
        @Nullable ClientRequest request,
        @Nullable ClientResponse response
    ); @Override @Nullable String getHeaderSingleValue(@Nullable ClientRequest request, @NotNull String headerKey); @Override @Nullable List<String> getHeaderMultipleValue(
        @Nullable ClientRequest request, @NotNull String headerKey
    ); @Override @Nullable String getSpanHandlerTagValue(
        @Nullable ClientRequest request, @Nullable ClientResponse response
    );  }
@Test public void getRequestPath_returns_request_URI_path() { String expectedPath = "/foo/bar/" + UUID.randomUUID().toString(); URI fullUri = URI.create(expectedPath + "?stuff=things"); doReturn(fullUri).when(requestMock).url(); assertThat(fullUri.toString()).contains("?"); assertThat(expectedPath).doesNotContain("?"); assertThat(fullUri.getPath()).isEqualTo(expectedPath); String result = implSpy.getRequestPath(requestMock); assertThat(result).isEqualTo(expectedPath); }
@Test public void getRequestPath_returns_null_when_passed_null() { assertThat(implSpy.getRequestPath(null)).isNull(); }
@Test public void getRequestPath_returns_null_when_request_url_null() { doReturn(null).when(requestMock).url(); assertThat(implSpy.getRequestPath(requestMock)).isNull(); }