tests/test_suppressWarnings.R

source("helper/helper.R")

if (getRversion() >= "4.0.0") {
  f = get("suppressWarnings", envir = baseenv())
  expect_same = makeCompareFun(f, backports:::suppressWarnings)

  expect_same(suppressWarnings(backports:::warningCondition("foo", "testWarning")), classes = "testWarning")
}
mllg/backports documentation built on March 15, 2023, 8:07 p.m.