tests/testthat/test-tx_curr.R

test_that("tx_curr filters only active clients", {
  expect_identical(
    tx_curr(ndr_example, status = "default"),
    ndr_example %>%
      subset(current_status_28_days == "Active" &
        !patient_has_died %in% TRUE)
  )
})

Try the tidyndr package in your browser

Any scripts or data that you put into this service are public.

tidyndr documentation built on April 8, 2022, 9:06 a.m.