tests/testthat/test-create_trait_pars.R

test_that("minimal use", {
  testthat::expect_silent(
    create_trait_pars(
      trans_rate = 0.5,
      immig_rate2 = 0.1,
      ext_rate2 = 0.2,
      ana_rate2 = 0.3,
      clado_rate2 = 0.4,
      trans_rate2 = 0.5,
      M2 = 1000
    )
  )
  out <- create_trait_pars(
    trans_rate = 0.5,
    immig_rate2 = 0.1,
    ext_rate2 = 0.2,
    ana_rate2 = 0.3,
    clado_rate2 = 0.4,
    trans_rate2 = 0.5,
    M2 = 1000
  )
  reference <- list(
    trans_rate = 0.5,
    immig_rate2 = 0.1,
    ext_rate2 = 0.2,
    ana_rate2 = 0.3,
    clado_rate2 = 0.4,
    trans_rate2 = 0.5,
    M2 = 1000
  )
  testthat::expect_equal(out, reference)
})

Try the DAISIE package in your browser

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

DAISIE documentation built on Oct. 22, 2023, 1:06 a.m.