Skip to content

Commit

Permalink
Confirm #106 is fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
richelbilderbeek committed Apr 1, 2024
1 parent 92a680c commit a8c6335
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 4 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ URL: https://docs.ropensci.org/babette/ (website),
https://github.com/ropensci/babette
BugReports: https://github.com/ropensci/babette/issues
Depends:
beautier (>= 2.6.11),
beautier (>= 2.6.12),
beastier (>= 2.5),
mauricer (>= 2.5.2),
R (>= 3.5.0),
Expand Down
37 changes: 34 additions & 3 deletions tests/testthat/test-issues.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
test_that("use", {

skip("#26")
if (!is_beast2_installed()) return()

filename <- get_babette_path(
Expand Down Expand Up @@ -42,7 +40,6 @@ test_that("use", {
})

test_that("use", {
skip("#26")
if (!is_beast2_installed()) return()
# Must be similar XML as
# beautier::get_beautier_path("rln_and_tipdates_babette_issue_26.xml")
Expand Down Expand Up @@ -112,3 +109,37 @@ test_that("clockRate.c ID and ClockPrior.c ID added twice", {
beastier::remove_beaustier_folders()
beastier::check_empty_beaustier_folders()
})


test_that("Issue 106. Issue #106", {

if (!is_on_ci()) return()
if (!is_beast2_installed()) return()

fasta_filename <- beautier::get_fasta_filename()
sample_interval <- 10000
mrca_pr <- beautier::create_mrca_prior(
taxa_names = beautier::get_taxa_names(fasta_filename),
is_monophyletic = TRUE,
mrca_distr = beautier::create_distr_normal(mean = 66, sigma = 1)
)

inf_model <- beautier::create_inference_model(
tree_prior = beautier::create_bd_tree_prior(),
clock_model = beautier::create_clock_model_rln(mean_clock_rate = ),
mcmc = beautier::create_mcmc(
chain_length = 1e6,
store_every = sample_interval
),
mrca_prior = mrca_pr,
beauti_options = beautier::create_beauti_options_v2_6()
)

expect_silent(
babette::bbt_run_from_model(
fasta_filename = fasta_filename,
inference_model = inf_model,
beast2_options = beastier::create_beast2_options(rng_seed = 42)
)
)
})

0 comments on commit a8c6335

Please sign in to comment.