tests/testthat/helpers-touch_file.R

library(testthatsomemore)

touch_file <- function(file, time = "1 minute from now") {
  testthatsomemore::pretend_now_is(time, {
    Sys.setFileTime(file, Sys.time())
  })
}
syberia/director documentation built on May 30, 2019, 10:40 p.m.