### Question:
EndpointInterceptorClientAdapter implements ClientInterceptor { public static ClientInterceptor[] wrapEndpointInterceptors(EndpointInterceptor[] endpointInterceptors) { if (endpointInterceptors!=null) { ClientInterceptor[] result = new ClientInterceptor[endpointInterceptors.length]; for (int i=0; i<endpointInterceptors.length; i++) { result[i]= new EndpointInterceptorClientAdapter(endpointInterceptors[i]); } return result; } else { return new ClientInterceptor[0]; } } EndpointInterceptorClientAdapter(EndpointInterceptor interceptor); static ClientInterceptor[] wrapEndpointInterceptors(EndpointInterceptor[] endpointInterceptors); boolean handleFault(MessageContext messageContext); void afterCompletion(MessageContext messageContext, Exception ex); boolean handleRequest(MessageContext messageContext); boolean handleResponse(MessageContext messageContext);  }### Answer:
@Test public void testWrapNull() { ClientInterceptor[] endpointInterceptors = EndpointInterceptorClientAdapter.wrapEndpointInterceptors(null); assertArrayEquals(new ClientInterceptor[0], endpointInterceptors); }
@Test public void testWrapEmpty() { ClientInterceptor[] endpointInterceptors = EndpointInterceptorClientAdapter.wrapEndpointInterceptors(new EndpointInterceptor[0]); assertArrayEquals(new ClientInterceptor[0], endpointInterceptors); }
@Test public void testWrapOne() { ClientInterceptor[] endpointInterceptors = EndpointInterceptorClientAdapter.wrapEndpointInterceptors(new EndpointInterceptor[]{new PayloadLoggingInterceptor()}); assertEquals(1, endpointInterceptors.length); assertEquals(EndpointInterceptorClientAdapter.class, endpointInterceptors[0].getClass()); }