Skip to content

Commit

Permalink
fix: minor correction to test_modelling
Browse files Browse the repository at this point in the history
  • Loading branch information
ntorresd committed Aug 14, 2023
1 parent 5e9fa31 commit 7465583
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions tests/testthat/test_modelling.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@ test_that("individual models", {
set.seed(1234) # For reproducibility

library(devtools)
library(dplyr)
library(vdiffr)

#----- Read and prepare data
data("serodata")
data_test <- serodata %>% prepare_serodata(alpha = 0.05)
data(chagas2012)
serodata <- prepare_serodata(chagas2012, alpha = 0.05)

data_constant_path <- testthat::test_path("extdata", "prev_expanded_constant.RDS")
data_tv_normal_path <- testthat::test_path("extdata", "prev_expanded_tv_normal.RDS")
Expand All @@ -23,7 +22,7 @@ test_that("individual models", {
#----- Test for the constant model

model_name <- "constant"
model_object <- run_seromodel(serodata = data_test,
model_object <- run_seromodel(serodata = serodata,
foi_model = model_name,
n_iters = 1000,
print_summary = FALSE)
Expand All @@ -37,7 +36,7 @@ test_that("individual models", {
#----- Test for the tv_normal model

model_name <- "tv_normal"
model_object <- run_seromodel(serodata = data_test,
model_object <- run_seromodel(serodata = serodata,
foi_model = model_name,
n_iters = 1000)

Expand All @@ -49,7 +48,7 @@ test_that("individual models", {
#----- Test for the tv_normal_log model

model_name <- "tv_normal_log"
model_object <- run_seromodel(serodata = data_test,
model_object <- run_seromodel(serodata = serodata,
foi_model = model_name,
n_iters = 1000)

Expand Down

0 comments on commit 7465583

Please sign in to comment.