Skip to content

Commit

Permalink
test instrumentation
Browse files Browse the repository at this point in the history
  • Loading branch information
wlandau committed Oct 22, 2024
1 parent 8da0cd9 commit 71e0ae3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/testthat/test-crew_controller_local.R
Original file line number Diff line number Diff line change
Expand Up @@ -282,11 +282,12 @@ crew_test("crew_controller_local() resource usage metric logging", {
crew_test_sleep()
})
x$start()
x$push(Sys.sleep(2))
x$push(name = "monitored_task", Sys.sleep(2))
x$wait(mode = "all", seconds_timeout = 30)
x$terminate()
expect_true(dir.exists(log))
data <- autometric::log_read(log)
expect_true(any("monitored_task" %in% data$phase))
expect_true(is.data.frame(data))
expect_gt(nrow(data), 0L)
expect_equal(unique(data$status), 0L)
Expand Down

0 comments on commit 71e0ae3

Please sign in to comment.