Skip to content

Commit

Permalink
test for overall findRecalSeries function
Browse files Browse the repository at this point in the history
  • Loading branch information
KristinaGomoryova committed Sep 13, 2024
1 parent b5ce0bf commit fc5f176
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
Binary file added tests/testthat/test-data/findRecalSeriesFALSE.rds
Binary file not shown.
Binary file added tests/testthat/test-data/findRecalSeriesTRUE.rds
Binary file not shown.
11 changes: 11 additions & 0 deletions tests/testthat/test-findRecalSeries.R
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,14 @@ patrick::with_parameters_test_that("Selection of the final series works", {
},
mode = c(TRUE, FALSE)
)

patrick::with_parameters_test_that("FindRecalSeries function works", {
df <- readRDS("test-data/scores_df_full.rds")
expected <- readRDS(file.path("test-data", paste0("findRecalSeries", mode, ".rds")))
n <- 3

actual <- find_final_series(df, n, mode)
expect_equal(actual, expected)
},
mode = c(TRUE, FALSE)
)

0 comments on commit fc5f176

Please sign in to comment.