Skip to content

Commit

Permalink
Resolved the issue with the testthat instance on `missing.contact.a…
Browse files Browse the repository at this point in the history
…ge`, which was introduced in the last update where `is.integer(3)` was changed to `2L` instead of `3L`.
  • Loading branch information
lwillem committed Dec 20, 2024
1 parent 2388d5b commit 7cc377e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/testthat/test-matrix.r
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,6 @@ test_that("Symmetric contact matrices with large normalisation weights throw a w
test_that("Contacts with an age below the age limits are excluded regardless of the missing.contact.age setting", {
expect_identical(ncol(contact_matrix(polymod, age.limits = c(10, 50), missing.contact.age = "remove")$matrix), 2L)
expect_identical(ncol(contact_matrix(polymod, age.limits = c(10, 50), missing.contact.age = "sample")$matrix), 2L)
expect_identical(ncol(contact_matrix(polymod, age.limits = c(10, 50), missing.contact.age = "keep")$matrix), 2L) # extra column for ages outside age limits (= NA)
expect_identical(ncol(contact_matrix(polymod, age.limits = c(10, 50), missing.contact.age = "keep")$matrix), 3L) # extra column for ages outside age limits (= NA)
expect_identical(ncol(contact_matrix(polymod, age.limits = c(10, 50), missing.contact.age = "ignore")$matrix), 2L)
})

0 comments on commit 7cc377e

Please sign in to comment.