inst/testme/test-batchtools_template.R

library(future)

message("*** batchtools_template() ...")

## NOTE: Here we use invalid 'workers = FALSE' in order to
## prevent the batchtools future from actually starting,
## because we cannot assume that system has these schedulers.
## NOTE: Some of them will give an earlier error because
## no default template file was found.
res <- try(plan(future.batchtools::batchtools_lsf, workers = FALSE))
stopifnot(inherits(res, "try-error"))

res <- try(plan(future.batchtools::batchtools_openlava, workers = FALSE))
stopifnot(inherits(res, "try-error"))

res <- try(plan(future.batchtools::batchtools_sge, workers = FALSE))
stopifnot(inherits(res, "try-error"))

res <- try(plan(future.batchtools::batchtools_slurm, workers = FALSE))
stopifnot(inherits(res, "try-error"))

res <- try(plan(future.batchtools::batchtools_torque, workers = FALSE))
stopifnot(inherits(res, "try-error"))

message("*** batchtools_template() ... DONE")

Try the future.batchtools package in your browser

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

future.batchtools documentation built on Oct. 19, 2026, 1:07 a.m.