ClientRequestContextAdapter { @Nullable static String serializationFormat(RequestLog requestLog) { final SerializationFormat serFmt = requestLog.scheme().serializationFormat(); return serFmt == SerializationFormat.NONE ? null : serFmt.uriText(); } private  ClientRequestContextAdapter();   }
@Test void serializationFormat() { final ClientRequestContext ctx1 = ClientRequestContext.of(HttpRequest.of(HttpMethod.GET, "/")); ctx1.logBuilder().serializationFormat(SerializationFormat.UNKNOWN); ctx1.logBuilder().endRequest(); ctx1.logBuilder().endResponse(); assertThat(ClientRequestContextAdapter.serializationFormat(ctx1.log().ensureComplete())) .isEqualTo("unknown"); final ClientRequestContext ctx2 = ClientRequestContext.of(HttpRequest.of(HttpMethod.GET, "/")); ctx2.logBuilder().endRequest(); ctx2.logBuilder().endResponse(); assertThat(ClientRequestContextAdapter.serializationFormat(ctx2.log().ensureComplete())).isNull(); }