tests/testthat/test-cff-git-hook.R

test_that("cff_git_hook_install errors when usethis is unavailable", {
  local_mocked_bindings(cff_has_usethis = function() FALSE)

  expect_snapshot(cff_git_hook_install(), error = TRUE)
})

Try the cffr package in your browser

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

cffr documentation built on Aug. 24, 2026, 5:11 p.m.