tests/testthat/test-list.R

context("list")

skip_on_cran()

skip_if_not_installed("modeltests")
library(modeltests)

test_that("not all lists can be tidied", {
  nl <- list(a = NULL)

  expect_error(tidy(nl), "No tidy method recognized for this list.")
  expect_error(glance(nl), "No glance method recognized for this list.")
})

Try the broom package in your browser

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

broom documentation built on July 9, 2023, 5:28 p.m.