DatasetCombiner { public static Collection<String> findGDSforGSE( Collection<String> seriesAccessions ) { Collection<String> associatedDatasetAccessions = new HashSet<>(); for ( String seriesAccession : seriesAccessions ) { associatedDatasetAccessions.addAll( DatasetCombiner.findGDSforGSE( seriesAccession ) ); } return associatedDatasetAccessions; } DatasetCombiner();  DatasetCombiner( boolean doSampleMatching ); static Collection<String> findGDSforGSE( Collection<String> seriesAccessions ); static Collection<String> findGDSforGSE( String seriesAccession ); static Collection<String> findGSEforGDS( String datasetAccession ); static Map<GeoPlatform, List<GeoSample>> getPlatformSampleMap( GeoSeries geoSeries ); Collection<String> findGDSforGDS( String datasetAccession ); GeoSampleCorrespondence findGSECorrespondence( Collection<GeoDataset> dataSets ); GeoSampleCorrespondence findGSECorrespondence( GeoSeries series );  }
@Test public void testFindGDSGrouping() { try { Collection<String> result = DatasetCombiner.findGDSforGSE( "GSE674" ); assertEquals( 2, result.size() ); assertTrue( result.contains( "GDS472" ) && result.contains( "GDS473" ) ); } catch ( RuntimeException e ) { if ( e.getCause() instanceof java.net.UnknownHostException ) { DatasetCombinerTest.log.warn( "Test skipped due to unknown host exception" ); return; } else if ( e.getCause() instanceof java.io.IOException && e.getCause().getMessage().contains( "503" ) ) { DatasetCombinerTest.log.warn( "Test skipped due to 503 from NCBI" ); DatasetCombinerTest.log.error( e, e ); return; } throw e; } }
@Test public void testFindGSE267() { Collection<String> result = DatasetCombiner.findGDSforGSE( "GSE267" ); assertEquals( 0, result.size() ); }