tests/testthat/test-mean_absorption.R

test_that("function works", {
  expect_equal(mean_absorption(c(48e5,28e9), 500, c(4, 94)), matrix(c(3216.7275)))
})


test_that("function does not works", {
  expect_error(mean_absorption(c(48e5,28e9), "head", c(4, 94)), "non-numeric argument to binary operator")
})

Try the tagtools package in your browser

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

tagtools documentation built on June 28, 2024, 5:07 p.m.