tests/testthat/test-progress-handler-logger.R

test_that("loggerr_out", {
  bar <- new.env(parent = emptyenv())
  bar$id <- "id"
  bar$current <- 13
  bar$total <- 113
  mockery::stub(logger_out, "Sys.time", .POSIXct(1623325865, tz = "CET"))
  expect_snapshot(logger_out(bar, "updated"))
})

Try the cli package in your browser

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

cli documentation built on March 31, 2023, 9:04 p.m.