tests/testthat/test-internet_connectivity.R

test_that(".rba_http_status works", {

  expect_type(
    object = .rba_http_status("200", verbose = TRUE),
    type = "character"
  )
  expect_regex(
    obj = .rba_http_status("599", verbose = TRUE),
    pattern = "redirection",
    ignore.case = TRUE
  )
  expect_error(
    object = .rba_http_status("999999", verbose = TRUE)
  )

})

Try the rbioapi package in your browser

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

rbioapi documentation built on April 4, 2025, 5:04 a.m.