tests/testthat/test_recent_changes.R

context("Recent changes")

test_that("Recentchanges feed entries can be retrieved through recent_changes", {
  skip_on_cran()
  expect_true({recent_changes("en","wikipedia", limit=1);TRUE})
})

test_that("recent_changes respects tags", {
  skip_on_cran()
  expect_true({recent_changes("en","wikipedia", limit=1, tag = "mobile edit");TRUE})
})

test_that("recent_changes respects types", {
  skip_on_cran()
  expect_true({recent_changes("en","wikipedia", limit=1, type = "new");TRUE})
})

test_that("recent_changes respects directional changes", {
  skip_on_cran()
  expect_true({recent_changes("en","wikipedia", limit=1, top = TRUE);TRUE})
})

Try the WikipediR package in your browser

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

WikipediR documentation built on June 22, 2024, 12:01 p.m.