R Under development (unstable) (2025-09-02 r88773 ucrt) -- "Unsuffered Consequences" Copyright (C) 2025 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > require(doRedis) Loading required package: doRedis Loading required package: foreach Loading required package: iterators > require(rredis) Loading required package: rredis Warning message: In library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : there is no package called 'rredis' > > compare <- function(x, y, label="unexpected result") + { + if(!isTRUE(all.equal(x, y))) stop(label) + } > > # covr can't detect coverage of worker routines run in separate > # processes. This example test explicitly constructs a work queue > # and runs a worker locally to test it. > if(Sys.getenv("TEST_DOREDIS") == "TRUE") + { + redisConnect() + redisFlushAll() + IDfile <- tempfile("doRedis") + zz <- file(IDfile,"w") + close(zz) + ID <- basename(IDfile) + ID <- gsub("\\\\","_",ID) + queue <- "jobs2" + queueEnv <- paste(queue,"env", ID, sep=".") + queueOut <- paste(queue,"out", ID, sep=".") + queueStart <- paste(queue,"start",ID, sep=".") + queueStart <- paste(queueStart, "*", sep="") + queueAlive <- paste(queue,"alive",ID, sep=".") + queueAlive <- paste(queueAlive, "*", sep="") + e <- new.env() + e$.Random.seed <- as.integer(c(1,2,3)) + redisSet(queueEnv, list(expr=as.symbol("j"), exportenv=e, packages=c())) + block <- list(`1`=1) + redisRPush(queue, list(ID=ID, argsList=block)) + redisWorker(queue, iter=1, timeout=1, log=stderr()) + redisConnect() + redisFlushAll() + } > > proc.time() user system elapsed 0.20 0.12 0.31