Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Hot fix] test when pop size is not constant was failing #235

Merged
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## User-visible changes

- `wwinference` now checks whether `site_pop` is unique per site (see issue [#223](https://github.com/CDCgov/ww-inference-model/issues/226) and reported by [@akeyel](https://github.com/akeyel)).
- `wwinference` now checks whether `site_pop` is fixed per site (see issue [#223](https://github.com/CDCgov/ww-inference-model/issues/226) and reported by [@akeyel](https://github.com/akeyel)).
kaitejohnson marked this conversation as resolved.
Show resolved Hide resolved

## Internal changes

Expand Down
5 changes: 3 additions & 2 deletions tests/testthat/test_preprocess_ww_data.R
Original file line number Diff line number Diff line change
Expand Up @@ -382,11 +382,12 @@ test_that("Function handles LOD values equal to concentration values", {

test_that("Constant population per site", {
wrong_pop <- ww_data
ww_data$site_pop <- sample(ww_data$site_pop)

wrong_pop$site_pop <- 1e6 + seq_len(nrow(ww_data))

expect_error(
preprocess_ww_data(
ww_data,
wrong_pop,
conc_col_name = "conc",
lod_col_name = "lod"
),
Expand Down
Loading