### Question:
ClientTypeHelper { public static String extractClientType(MediaType mediaType){ return mediaType == null ? null : extractClientType(mediaType.toString()); }  static String extractClientType(MediaType mediaType); static String extractClientType(String mediaType);  }### Answer:
@Test public void extractClientType_mediaTypeIsNull_success() { assertNull(ClientTypeHelper.extractClientType((MediaType) null)); }
@Test public void extractClientType_mediaTypeHasClientType_success() { String result = ClientTypeHelper.extractClientType(ResourceMediaType.FOLDER_JSON); assertEquals(result, ResourceMediaType.FOLDER_CLIENT_TYPE); }
@Test public void extractClientType_mediaTypeMissesClientType_success() { String result = ClientTypeHelper.extractClientType(MediaType.APPLICATION_JSON); assertNull(result); }
@Test public void extractClientType_mediaTypeHasWrongServiceName_success() { String result = ClientTypeHelper.extractClientType("application/execution.multiAxesQuery+json"); assertNull(result, ResourceMediaType.FOLDER_CLIENT_TYPE); }