tests/testthat/helper.R

testthat::set_state_inspector(function() {
  list(
    connections = getAllConnections(),
    the_throttle = as.list(the$throttle)
  )
})

expect_redacted <- function(req, expected) {
  expect_equal(which_redacted(req$headers), expected)
}

Try the httr2 package in your browser

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

httr2 documentation built on Aug. 8, 2025, 7:52 p.m.