diff --git a/tests/testthat/test-enhancements.R b/tests/testthat/test-enhancements.R index c5c14cf..26ad60c 100644 --- a/tests/testthat/test-enhancements.R +++ b/tests/testthat/test-enhancements.R @@ -28,7 +28,7 @@ test_that("fingertips_redred returns correct column number table for AreaTypeID }) test_that("fingertips_redred returns correct column number table for AreaTypeID 202", { skip_on_cran() - expect_equal(ncol(fingertips_redred(90776, AreaTypeID = 202, Comparator = "Goal")), numcols) + expect_equal(ncol(fingertips_redred(90776, AreaTypeID = 402, Comparator = "Goal")), numcols) }) diff --git a/tests/testthat/test-extract.R b/tests/testthat/test-extract.R index a882c96..4c3b00c 100644 --- a/tests/testthat/test-extract.R +++ b/tests/testthat/test-extract.R @@ -163,13 +163,17 @@ test_that("the correct url produced when AreaTypeID = 'All' and ProfileID provid test_that("the correct url produced when AreaTypeID = 'All' and IndicatorID provided", { skip_on_cran() expect_equal(fingertips_data(IndicatorID = 90362, ProfileID = 156, AreaTypeID = "All", url_only = TRUE), - c("https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=502&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", + c( + "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=502&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", + "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=501&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=402&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=302&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", + "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=301&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=202&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=102&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", - "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=15&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes" , - "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=6&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes")) + "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=15&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes", + "https://fingertips.phe.org.uk/api/all_data/csv/by_indicator_id?indicator_ids=90362&child_area_type_id=6&parent_area_type_id=15&profile_id=156&include_sortable_time_periods=yes" + )) }) diff --git a/tests/testthat/test-metadata.R b/tests/testthat/test-metadata.R index 4a5b2e1..677680a 100644 --- a/tests/testthat/test-metadata.R +++ b/tests/testthat/test-metadata.R @@ -1,7 +1,7 @@ library(testthat) library(fingertipsR) -ncols <- 30 +ncols <- 32 # Error tests -------------------------------------------------------------