tests/testthat/test_valid_obj.R

library(artyfarty)

context("themes return correctly")

test_that("themes return a theme object", {

  theme_funcs<-Filter(function(o) grepl("theme_", o), ls("package:artyfarty"))

  for(th in theme_funcs){

    expect_s3_class(get(th)(), "theme")
  }

})
datarootsio/artyfarty documentation built on May 14, 2019, 9:42 a.m.