diff --git a/tests/testthat/test-species_code.R b/tests/testthat/test-species_code.R index fd750ab..0b90ec2 100644 --- a/tests/testthat/test-species_code.R +++ b/tests/testthat/test-species_code.R @@ -1,8 +1,4 @@ -context("species_code") - test_that("species_code works correctly", { - skip_on_cran() - sp1 <- species_code("anhinga novaehollandiae") sp2 <- species_code("Anhinga anhinga") expect_is(sp1, "character") @@ -13,11 +9,8 @@ test_that("species_code works correctly", { }) test_that("species_code fails correctly", { - skip_on_cran() expect_error(species_code()) expect_error(species_code(1), "sciname is not a character vector") expect_error(species_code(c("anhinga novaehollandiae", "anhinga anhinga")), "length\\(sciname\\) not equal to 1") expect_error(species_code("Anhinga fakei"), "No species in eBird taxonomy with matching scientific name.") }) - -