tests/testthat/test_dim_data.R

test_that("Check number of rows for 2015 accidents file", {
  testthat::expect_equal(nrow(fars_read_years(2015)[[1]]), 32166)
})

test_that("Check number of rows for 2014 accidents file", {
  testthat::expect_equal(nrow(fars_read_years(2014)[[1]]), 30056)
})


test_that("Check number of rows for 2015 accidents file", {
  testthat::expect_equal(nrow(fars_read_years(2013)[[1]]), 30202)
})
Daviddlhy/farsdata documentation built on Dec. 31, 2020, 11:55 a.m.