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)
  ))

})

Try the extraDistr package in your browser

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

extraDistr documentation built on May 29, 2024, 9:31 a.m.