tests/testthat/test-summary.R

test_that("Oz_butterflies_summary works", {
  # This really just checks that the function runs without error and returns something
  # Just read the test database
  sum <- Oz_butterflies_summary(testthat::test_path("testdata/db"))
  expect_equal(sum$Families, 5)
  expect_gte(ncol(sum), 11)
})

Try the ButtR package in your browser

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

ButtR documentation built on April 22, 2026, 1:07 a.m.