tests/testthat/test-is_well_on_edge.R

# WARNING - Generated by {fusen} from dev/flat_utils.Rmd: do not edit by hand

test_that("is_well_on_edge works", {
  expect_equal(
    which(is_well_on_edge(1:96, plate_layout = 96)),
    c(1:13, 24, 25, 36, 37, 48, 49, 60, 61, 72, 73, 84:96)
  )
  expect_false(
    is_well_on_edge(23, plate_layout = 96)
  )
  expect_true(
    is_well_on_edge(23, plate_layout = 384)
  )
})
test_that("is_well_on_edge fails", {
  expect_error(
    is_well_on_edge(0), "The well number is not a positive only vector"
  )
  expect_error(
    is_well_on_edge(NA, plate_layout = 96),
    "The well number is not an numeric vector"
  )
  expect_error(
    is_well_on_edge(2, plate_layout = 84),
    "The expected plate layouts are 96 or 384 wells."
  )
})

Try the maldipickr package in your browser

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

maldipickr documentation built on Sept. 13, 2024, 1:12 a.m.