Search in sources :

Example 1 with DatasetImporterForCoetzer

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

the class DatasetImporterFactoryImplIT method createAfrotropicalBees.

@Test
public void createAfrotropicalBees() throws StudyImporterException, DatasetRegistryException, IOException {
    final DatasetRegistryGitHubRemote datasetFinderGitHubRemote = new DatasetRegistryGitHubRemote(inStream -> inStream);
    String repo = "globalbioticinteractions/Catalogue-of-Afrotropical-Bees";
    DatasetImporter importer = importerFor(datasetFinderGitHubRemote, repo);
    assertThat(importer, is(notNullValue()));
    assertThat(importer, is(instanceOf(DatasetImporterForCoetzer.class)));
    assertThat(((DatasetImporterForCoetzer) importer).getDataset(), is(notNullValue()));
    assertThat(((DatasetImporterForCoetzer) importer).getDataset().retrieve(URI.create("archive")), is(notNullValue()));
}
Also used : DatasetImporterForCoetzer(org.eol.globi.data.DatasetImporterForCoetzer) DatasetRegistryGitHubRemote(org.globalbioticinteractions.dataset.DatasetRegistryGitHubRemote) Matchers.containsString(org.hamcrest.Matchers.containsString) BaseDatasetImporter(org.eol.globi.data.BaseDatasetImporter) DatasetImporter(org.eol.globi.data.DatasetImporter) Test(org.junit.Test)

Aggregations

BaseDatasetImporter (org.eol.globi.data.BaseDatasetImporter)1 DatasetImporter (org.eol.globi.data.DatasetImporter)1 DatasetImporterForCoetzer (org.eol.globi.data.DatasetImporterForCoetzer)1 DatasetRegistryGitHubRemote (org.globalbioticinteractions.dataset.DatasetRegistryGitHubRemote)1 Matchers.containsString (org.hamcrest.Matchers.containsString)1 Test (org.junit.Test)1