JumpToCodeClient { public Set<JumpToCodeService.Capabilities> capabilities() throws IOException { final Map<String, String> stringStringMap = executeAndGetHeaders(new GetMethod(getUrl())); final Set<String> definedCapabilities = Arrays .stream(JumpToCodeService.Capabilities.values()) .map(JumpToCodeService.Capabilities::getValue) .collect(Collectors.toSet()); return Splitter .on(",") .trimResults() .splitToList(stringStringMap.getOrDefault("plugin-features", "")) .stream() .filter(definedCapabilities::contains) .map(capabilitiesMap::get) .collect(Collectors.toSet()); } JumpToCodeClient(Configuration configuration); String getContent(final LocationInfo locationInfo); Ide getIde(String host, int port); String getUrl(LocationInfo locationInfo); boolean isJumpable(final LocationInfo locationInfo); Ide getIde(); Set<JumpToCodeService.Capabilities> capabilities(); Set<String> loggerPatterns(); void clearLocationCaches();  }
@Test public void testCapabilities() throws Exception { Assertions.assertThat(jumpToCodeClient.capabilities()) .containsOnly( JumpToCodeService.Capabilities.AllFile, JumpToCodeService.Capabilities.ContentByLine, JumpToCodeService.Capabilities.ContentByMessage, JumpToCodeService.Capabilities.JumpByLine, JumpToCodeService.Capabilities.JumpByMessage, JumpToCodeService.Capabilities.LoggersConfig ); }