From b0542c99d3db995ae975ac8649b40bef9172c5aa Mon Sep 17 00:00:00 2001 From: Rich FitzJohn Date: Wed, 6 Nov 2024 13:51:51 +0000 Subject: [PATCH] Add integration test --- tests/testthat/test-runner-callr.R | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/testthat/test-runner-callr.R b/tests/testthat/test-runner-callr.R index cae9e025..89ae4038 100644 --- a/tests/testthat/test-runner-callr.R +++ b/tests/testthat/test-runner-callr.R @@ -30,3 +30,13 @@ test_that("can continue parallel runs", { expect_equal(res2b, res1b) }) + + +test_that("can produce progress bars", { + m <- monty_example("banana") + s <- monty_sampler_random_walk(vcv = diag(2) * 0.02) + r <- monty_runner_callr(2, progress = TRUE) + res <- evaluate_promise(monty_sample(m, s, 100, n_chains = 4, runner = r)) + expect_match(res$messages, "Sampled 400 steps across 4 chains in", + all = FALSE) +})