tests/testthat/files/integration_test_cases/q1.R

test <- list(
  name = "q1",
  cases = list(
    ottr::TestCase$new(
      name = "q1-1",
      code = {
        testthat::expect_true(x >= 1)
        testthat::expect_true(x <= 3)
      }
    ),
    ottr::TestCase$new(
      name = "q1-2",
      hidden = TRUE,
      code = {
        testthat::expect_equal(x, 2)
      }
    )
  )
)

Try the ottr package in your browser

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

ottr documentation built on May 29, 2024, 3:31 a.m.