tests/testthat/test-01-getData.R

test_that("getData() actually retrieves all data", {
  df <- getData()
  expect_match(levels(df$source)[1],"14CSea")
  expect_match(levels(df$source)[2],"CIMA")
  expect_match(levels(df$source)[3],"IntChron")
  expect_match(levels(df$source)[4],"LiVES")
  expect_type(getData(db="IntChron",category = "Location", field = "latitude")[[1]], "double")
  expect_warning(getData(db="IntChron",category = "Location", field = "measure"),NULL)
})

Try the IsoMemo package in your browser

Any scripts or data that you put into this service are public.

IsoMemo documentation built on Nov. 3, 2023, 5:09 p.m.