tests/testthat/test-plot_cases_province.R

library(ggplot2)
library(tidyr)
China_type <- COVID19CHN::China_covid19 %>%
  
  pivot_longer(cols = c("Confirmed",
                        "Deaths",
                        "Recovered"),
               names_to = "Type",
               values_to = "Cases") 

test_that("plot_cases_province", {
  testthat::expect_true(is.ggplot(plot_cases_province(China_type))
                        
  )
  })
etc5523-2020/r-package-assessment-Lulu-Pi documentation built on Jan. 1, 2021, 1:11 a.m.