tests/testthat/test_collections.R

context("lookup_collections")

test_that("lookup_collections returns tweets data", {
  skip_on_cran()
  token <- readRDS("twitter_tokens")

  x <- lookup_collections("custom-539487832448843776", token = token)
  class(x)
  expect_equal(is.list(x), TRUE)
  expect_named(x)
  expect_true(all(c("response", "objects") %in% names(x)))
})

Try the rtweet package in your browser

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

rtweet documentation built on Jan. 11, 2020, 9:11 a.m.