From d0f3e200230f24cac4d010162340ab67d0a10c04 Mon Sep 17 00:00:00 2001 From: Kiernan Nicholls Date: Sat, 27 Feb 2021 11:45:39 -0500 Subject: [PATCH] Test for station error with many calls --- tests/testthat/test-rail-info.R | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/testthat/test-rail-info.R b/tests/testthat/test-rail-info.R index c311882..d0dbfd7 100644 --- a/tests/testthat/test-rail-info.R +++ b/tests/testthat/test-rail-info.R @@ -8,3 +8,7 @@ test_that("stations info is listed for multiple stations", { expect_type(s$LineCodes, "list") expect_gt(length(unique(s$Code)), 1) }) + +test_that("station info fails for more than 9", { + expect_error(station_info(StationCode = metro_stations[1:10])) +})