diff options
author | Johannes Ranke <jranke@uni-bremen.de> | 2020-04-08 10:49:32 +0200 |
---|---|---|
committer | Johannes Ranke <jranke@uni-bremen.de> | 2020-04-08 10:49:32 +0200 |
commit | 636c585895aacaae95d739201e856252f24fec1b (patch) | |
tree | 539066e22d9b4f6b87e73c64fdc1b1e7cf86689e /tests/testthat | |
parent | d75cc396f3e93b06ba1c7a165543fe885ff9c69c (diff) |
Use two assignments to avoid skipping another test
Diffstat (limited to 'tests/testthat')
-rw-r--r-- | tests/testthat/test_tests.R | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/testthat/test_tests.R b/tests/testthat/test_tests.R index ddf8e1a0..3d1c136c 100644 --- a/tests/testthat/test_tests.R +++ b/tests/testthat/test_tests.R @@ -57,7 +57,11 @@ test_that("Updating fitted models works", { }) test_that("We can do a likelihood ratio test using an update specification", { - skip("This errors out if called by testthat while it works in a normal R session") + # The following two assignments were made so the update.mkinfit function called + # by lrtest.mkinfit finds these objects when lrtest.mkinfit is called by + # testthat + assign("f_2_mkin", f_2_mkin, globalenv()) + assign("DFOP_par_c", DFOP_par_c, globalenv()) test_2_mkin_k2 <- lrtest(f_2_mkin, fixed_parms = c(k2 = 0)) expect_equivalent(test_2_mkin_k2[["2", "Pr(>Chisq)"]], 4.851e-8, tolerance = 1e-8) test_2_mkin_tc <- lrtest(f_2_mkin, error_model = "tc") |