tests/testthat/test-add.R

context("Adding plot elements")

test_that("Mapping class is preserved when adding uneval objects", {
  p <- ggplot(mtcars) + aes(wt, mpg)
  expect_identical(class(p$mapping), "uneval")
})
jayhesselberth/ggplot2-search documentation built on May 9, 2019, 8:06 p.m.