tests/testthat/test-bus-departs.R

test_that("bus stop schedule for single stop", {
  skip_if_no_key()
  Sys.sleep(0.11)
  d <- bus_departs(StopID = 1000001)
  expect_length(d, 9)
  expect_s3_class(d, "data.frame")
  expect_s3_class(d$ScheduleTime, "POSIXct")
})

Try the metro package in your browser

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

metro documentation built on May 29, 2024, 8:32 a.m.