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: %s != %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 April 16, 2025, 9:08 a.m.