tests/testthat/test-logout_db.R

test_that("logout_db rejects bad input parameters", {
  expect_error(logout_db(vb = -1))
  expect_error(logout_db(vb = 3))
  expect_error(logout_db(vb = "a"))
  expect_error(logout_db(vb = c(TRUE, FALSE)))
})

test_that("logout_db returns logical", {
  expect_true(is.logical(logout_db()))
})

# Actually log out
logout_db()

Try the databraryr package in your browser

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

databraryr documentation built on Sept. 11, 2024, 6:48 p.m.