diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/testthat/illparms_hfits_synth_no_ranef_auto.txt | 4 | ||||
-rw-r--r-- | tests/testthat/print_hfits_synth_no_ranef_auto.txt | 9 | ||||
-rw-r--r-- | tests/testthat/test_mhmkin.R | 14 |
3 files changed, 25 insertions, 2 deletions
diff --git a/tests/testthat/illparms_hfits_synth_no_ranef_auto.txt b/tests/testthat/illparms_hfits_synth_no_ranef_auto.txt new file mode 100644 index 00000000..a64ed222 --- /dev/null +++ b/tests/testthat/illparms_hfits_synth_no_ranef_auto.txt @@ -0,0 +1,4 @@ + error +degradation const tc + SFO sd(parent_0) + FOMC b.1 diff --git a/tests/testthat/print_hfits_synth_no_ranef_auto.txt b/tests/testthat/print_hfits_synth_no_ranef_auto.txt new file mode 100644 index 00000000..9af1cbcd --- /dev/null +++ b/tests/testthat/print_hfits_synth_no_ranef_auto.txt @@ -0,0 +1,9 @@ +<mhmkin> object +Status of individual fits: + + error +degradation const tc + SFO OK OK + FOMC OK OK + +OK: Fit terminated successfully diff --git a/tests/testthat/test_mhmkin.R b/tests/testthat/test_mhmkin.R index 9fd29c50..93333ac1 100644 --- a/tests/testthat/test_mhmkin.R +++ b/tests/testthat/test_mhmkin.R @@ -38,12 +38,22 @@ test_that("Multiple hierarchical kinetic models can be fitted and diagnosed", { expect_known_output(print(test_summary, digits = 1), "summary_hfit_sfo_tc.txt") - # It depends on the platform exactly which of the - # SFO datasets fail to converge with FOMC + # It depends on the platform exactly which of the datasets fail to converge + # with FOMC, because they were generated to be SFO skip_on_travis() expect_known_output( print(fits_synth_const), "print_fits_synth_const.txt") + hfits_no_ranef_auto <- update(hfits, no_random_effect = "auto", auto_ranef_threshold = 2) + + expect_known_output( + print(hfits_no_ranef_auto), + "print_hfits_synth_no_ranef_auto.txt") + + expect_known_output( + print(illparms(hfits_no_ranef_auto)), + "illparms_hfits_synth_no_ranef_auto.txt") + }) |