tests/testthat/helpers.R

expect_equal_color <- function(object, expected, tol = 0) {
  res <- all(abs(col2rgb(object) - col2rgb(expected)) <= tol)
  expect_true(res)
}
EmilHvitfeldt/prismatic documentation built on April 15, 2024, 3:24 p.m.