### Question:
WorkItemDefinitionStandaloneClientService implements WorkItemDefinitionClientService { protected static String iconDataUri(String iconUri, String iconData) { String[] iconUriParts = iconUri.split("\\."); if (iconUriParts.length > 1) { int fileTypeIndex = iconUriParts.length - 1; String fileType = iconUriParts[fileTypeIndex]; return "data:image/" + fileType + ";base64, " + iconData; } return iconData; } @Inject  WorkItemDefinitionStandaloneClientService(final Promises promises,
                                                     final WorkItemDefinitionCacheRegistry registry,
                                                     final ResourceContentService resourceContentService,
                                                     final WorkItemIconCache workItemIconCache); @PostConstruct void init(); @Produces @Default @Override WorkItemDefinitionRegistry getRegistry(); @Override Promise<Collection<WorkItemDefinition>> call(final Metadata input); @PreDestroy void destroy();  }### Answer:
@Test public void testIconDataUri() { final String testData = "testData"; final String iconDataUri = WorkItemDefinitionStandaloneClientService.iconDataUri("test.png", testData); final String badUri = WorkItemDefinitionStandaloneClientService.iconDataUri("bad uri", testData); assertEquals("data:image/png;base64, testData", iconDataUri); assertEquals(testData, badUri); }