From 92bd47bf45cebe660c5e7f392a4ee19f704d8a19 Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Tue, 25 Oct 2022 16:12:39 +0200 Subject: Address platform dependencies that surfaced on travis --- tests/testthat/test_mhmkin.R | 13 +++++++++---- tests/testthat/test_saemix_parent.R | 2 +- 2 files changed, 10 insertions(+), 5 deletions(-) (limited to 'tests') diff --git a/tests/testthat/test_mhmkin.R b/tests/testthat/test_mhmkin.R index eced5583..fc588473 100644 --- a/tests/testthat/test_mhmkin.R +++ b/tests/testthat/test_mhmkin.R @@ -9,10 +9,6 @@ test_that("Multiple hierarchical kinetic models can be fitted and diagnosed", { fits_synth_tc <- suppressWarnings( update(fits_synth_const, error_model = "tc")) - expect_known_output( - print(fits_synth_const), - "print_fits_synth_const.txt") - hfits <- mhmkin(list(fits_synth_const, fits_synth_tc)) expect_known_output( @@ -40,4 +36,13 @@ 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 + skip_on_travis() + + expect_known_output( + print(fits_synth_const), + "print_fits_synth_const.txt") + }) diff --git a/tests/testthat/test_saemix_parent.R b/tests/testthat/test_saemix_parent.R index 0579f22f..39f69f51 100644 --- a/tests/testthat/test_saemix_parent.R +++ b/tests/testthat/test_saemix_parent.R @@ -111,7 +111,7 @@ test_that("Parent fits using saemix are correctly implemented", { transformations = "mkin") expect_equal( log(endpoints(dfop_saemix_1)$distimes[1:2]), - log(endpoints(sforb_saemix_1)$distimes[1:2]), tolerance = 0.01) + log(endpoints(sforb_saemix_1)$distimes[1:2]), tolerance = 0.03) expect_equal( log(endpoints(sforb_saemix_1)$distimes[1:2]), log(endpoints(sforb_saemix_2)$distimes[1:2]), tolerance = 0.01) -- cgit v1.2.1