inst/testme/_prologue/050.utils.R

assert_identical_sets <- function(a, b) {
  a <- sort(a)
  b <- sort(b)
  if (!identical(a, b)) {
    stop(sprintf("Non-identical sets: c(%s) != c(%s)",
         paste(sQuote(a), collapse = ", "),
         paste(sQuote(b), collapse = ", ")))
  }
}

Try the globals package in your browser

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

globals documentation built on June 8, 2025, 12:48 p.m.