# NOT RUN {
should_fail <- try(req_pkgs(linear_reg()), silent = TRUE)
should_fail
linear_reg() %>%
set_engine("glmnet") %>%
req_pkgs()
linear_reg() %>%
set_engine("lm") %>%
fit(mpg ~ ., data = mtcars) %>%
req_pkgs()
# }
Run the code above in your browser using DataLab