BioQueryService extends AbstractQueryService { protected static List<String> getPathQueryViews(String[] views) { if (views == null || views.length < 1) { return null; } List<String> viewList = new ArrayList<String>(); for (String view : views) { viewList.add(view.trim()); } return viewList; } BioQueryService(InterMineAPI im); PrintWriter getPrintWriter(); OutputStream getOutputStream(); @Override Format getDefaultFormat();  }
@Test public void testGetPathQueryViews() { assertNull(BioQueryService.getPathQueryViews(nullView)); assertNull(BioQueryService.getPathQueryViews(emptyView)); assertEquals(Arrays.asList("abc;d"), BioQueryService.getPathQueryViews(badView)); assertEquals(Arrays.asList("Gene.secondaryIdentifier", "Gene.symbol", "Gene.primaryIdentifier", "Gene.organism.name"), BioQueryService.getPathQueryViews(geneView)); assertEquals(Arrays.asList("Protein.primaryIdentifier", "Protein.primaryAccession", "Protein.organism.name", "Protein.genes.secondaryIdentifier", "Protein.genes.symbol", "Protein.genes.primaryIdentifier", "Protein.genes.organism.name"), BioQueryService.getPathQueryViews(ProteinView)); }