tests/testthat/test_vectorization.R

test_that("Fix for #16 works", {

  test_dat <- data.frame(
      q = c(1, 10, 10, 100),
      size = c(10, 100, 1000, 1000)
    )

  # This failed in #16
  testthat::expect_visible(with(
    test_dat,
    pbbinom(q, size, 1, 1)
  ))

  testthat::expect_visible(with(
    test_dat,
    pbnbinom(q, size, 1, 1)
  ))

})
twolodzko/extraDistr documentation built on Dec. 4, 2023, 8:56 p.m.