From 3eee6784032f342832396593c10cd8193579f431 Mon Sep 17 00:00:00 2001 From: Andrea-Havron-NOAA Date: Wed, 19 Jun 2024 18:18:07 -0500 Subject: [PATCH] add test --- tests/testthat/test-prior-multi-module.R | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/testthat/test-prior-multi-module.R b/tests/testthat/test-prior-multi-module.R index 2eee669..c3f2848 100644 --- a/tests/testthat/test-prior-multi-module.R +++ b/tests/testthat/test-prior-multi-module.R @@ -111,6 +111,7 @@ DataLL2$set_distribution_links("data", Pop2$get_id(), Pop2$get_module_name(), "l #set up shared prior for logk GrowthKPrior <- new(NormalLPDF) GrowthKPrior$expected_value <- new(VariableVector, rep(mu[2], 2), 2) +# GrowthKPrior$expected_value <- new(VariableVector, rep(mu[2], 1), 1) GrowthKPrior$input_type <- "prior" GrowthKPrior$log_sd[1]$value <- log(0.1579867) #link prior log-likelihood to the logk parameters from vonB1 and vonB2 @@ -128,6 +129,10 @@ Data <- list( y = get_data_vector() ) +test_that("check input data", { + expect_equal(c(length.data1, length.data2), Data$y) +}) + #create a parameter list Parameters <- list( p = get_parameter_vector()