tests/testthat/test-zzz.R

testthat::test_that("package initialization", {

  # reset origin options
  nms <- names(options())
  nms <- nms[grepl("^origin\\.", nms)]
  do.call(options, stats::setNames(lapply(nms, function(x) NULL), nms))
  testthat::expect_null(.onLoad())
  testthat::expect_null(.onLoad())

})

Try the origin package in your browser

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

origin documentation built on April 3, 2025, 11:03 p.m.