tests/testthat/test-average_fre_z.R

set.seed(4)

test_that("'average_fre_z()' calculates the expected
          z_score of -0.2979435", {
            expect_equal(
              average_fre_z(bodyweight, obs, reps = 10) %>%
                           dplyr::mutate(z_score = round(z_score, digits = 4)) %>%
                           dplyr::select(z_score) %>%
                           dplyr::pull(), -0.2979)
          })
josh-mc/fabricated documentation built on April 25, 2022, 1:31 p.m.