tests/testthat/test-assign_country.R

test_that("country = 'all' returns the expected output", {
  expect_equal(assign_country(country = "all"), all_countries)
})

test_that("Arguments other than 'all' are returned as is", {
  country <- c("ALB", "CHN")
  expect_equal(assign_country(country), country)
})

Try the povcalnetR package in your browser

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

povcalnetR documentation built on July 8, 2020, 6:48 p.m.