tests/testthat/test-function-date_range_CEST.R

#
# This test file has been generated by kwb.test::create_test_files()
#

test_that("date_range_CEST() works", {

  expect_error(
    kwb.datetime:::date_range_CEST(year = 1)
    # all(year >= 1980) is not TRUE
  )
   expect_error(
    kwb.datetime:::date_range_CEST(year = "a")
    # is.numeric(year) is not TRUE
  )
   expect_error(
    kwb.datetime:::date_range_CEST(year = list(key = c("a", "b"), value = 1:2))
    # (list) object cannot be coerced to type 'double'
  )

})
KWB-R/kwb.datetime documentation built on July 9, 2021, 10:28 p.m.