tests/testthat/test-utils.R

test_that("the console glyphs are the ones of the lab mapping", {
    # Regression: the information glyph was an inverted exclamation mark.
    expect_identical(unname(get_colored_symbol("info", color = FALSE)), "\u2139")
    expect_identical(unname(get_colored_symbol("success", color = FALSE)), "\u2714")
})

test_that("a missing suggested package stops with the reason and installs nothing", {
    expect_error(require_package("volumrNoSuchPackage"),
                 "install.packages\\(\"volumrNoSuchPackage\"\\)")
    expect_true(require_package("tools"))
    expect_false("package:tools" %in% search())
})

Try the volumr package in your browser

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

volumr documentation built on Dec. 2, 2026, 5:07 p.m.