Search in sources :

Example 1 with DatasetImporterForWood

use of org.eol.globi.data.DatasetImporterForWood in project eol-globi-data by jhpoelen.

the class DatasetImporterFactoryImplIT method createWood.

@Test
public void createWood() throws StudyImporterException, DatasetRegistryException, IOException {
    final DatasetRegistryGitHubRemote datasetFinderGitHubRemote = new DatasetRegistryGitHubRemote(inStream -> inStream);
    DatasetImporter importer = importerFor(datasetFinderGitHubRemote, "globalbioticinteractions/wood2015");
    assertThat(importer, is(notNullValue()));
    assertThat(importer, is(instanceOf(DatasetImporterForWood.class)));
    DatasetImporterForWood importerz = (DatasetImporterForWood) importer;
    assertThat(importerz.getSourceCitation(), containsString("Wood"));
    assertThat(importerz.getDataset().retrieve(URI.create("links")).toString(), is(notNullValue()));
}
Also used : DatasetRegistryGitHubRemote(org.globalbioticinteractions.dataset.DatasetRegistryGitHubRemote) BaseDatasetImporter(org.eol.globi.data.BaseDatasetImporter) DatasetImporter(org.eol.globi.data.DatasetImporter) DatasetImporterForWood(org.eol.globi.data.DatasetImporterForWood) Test(org.junit.Test)

Aggregations

BaseDatasetImporter (org.eol.globi.data.BaseDatasetImporter)1 DatasetImporter (org.eol.globi.data.DatasetImporter)1 DatasetImporterForWood (org.eol.globi.data.DatasetImporterForWood)1 DatasetRegistryGitHubRemote (org.globalbioticinteractions.dataset.DatasetRegistryGitHubRemote)1 Test (org.junit.Test)1