File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed
Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -19,15 +19,15 @@ extract <- function(recipe) {
1919 recipe
2020}
2121
22- # Tests
23- test_that(" Check that epi_ahead shifts properly" , {
24- expect_identical(step_naomit2(r ),
25- r %> %
26- step_naomit(all_predictors()) %> %
27- step_naomit(all_outcomes(), skip = TRUE ))
28- })
29-
30- z <- step_naomit2(r )
22+ z1 <- step_naomit2(r )
3123z2 <- r %> %
3224 step_naomit(all_predictors()) %> %
3325 step_naomit(all_outcomes(), skip = TRUE )
26+
27+ # Tests
28+ test_that(" Check that both functions behave the same way" , {
29+ expect_identical(z1 $ steps [[3 ]][- 1 ][- 5 ],z2 $ steps [[3 ]][- 1 ][- 5 ])
30+ expect_identical(z1 $ steps [[4 ]][- 1 ][- 5 ],z2 $ steps [[4 ]][- 1 ][- 5 ])
31+ expect_identical(class(z1 $ steps [[3 ]]),class(z2 $ steps [[3 ]]))
32+ expect_identical(class(z1 $ steps [[4 ]]),class(z2 $ steps [[4 ]]))
33+ })
You can’t perform that action at this time.
0 commit comments