tests/testthat/test-age_format.R

test_that("format ages", {

  ages_standard <- c("13", "25", NA, "SR", "27")

  ages_test <- age_format(c("13-06", "25-03", NA, "SR", "27-94"))

  expect_equivalent(ages_standard, ages_test)
})

# testthat::test_file("tests/testthat/test-age_format.R")

Try the SwimmeR package in your browser

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

SwimmeR documentation built on March 31, 2023, 8:27 p.m.