tests/testthat/test-catch_error.R

context("catch_error")

test_that("catch_error works", {
  library(purrr)
  out <- fcuk:::regex_rules()$error %>% 
    map_chr(~catch_error(.x)) %>% 
    unique()
  
  expect_equal(out, c("sl","iri","dplir"))
})

Try the fcuk package in your browser

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

fcuk documentation built on May 1, 2019, 10:22 p.m.