tests/testthat/test-available_series.R

test_that("available_series returns a data frame", {
  
  skip_on_cran()
  skip_if_offline()
  
  x <- available_series(label = FALSE)
  
  expect_s3_class(x, "data.frame")
  
  expect_true(all(
    c(
      "code",
      "name",
      "theme",
      "source",
      "freq",
      "lastupdate",
      "status"
    ) %in% names(x)
  ))
  
})

Try the ipeadatar package in your browser

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

ipeadatar documentation built on May 28, 2026, 5:08 p.m.