From f4febeab16eedffb5e074fc2d4f348fb688432b2 Mon Sep 17 00:00:00 2001 From: Carson Date: Wed, 23 Nov 2022 16:35:37 -0600 Subject: [PATCH] Get rid of warnings about qplot() usage in tests --- tests/testthat/test-test-server.R | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/testthat/test-test-server.R b/tests/testthat/test-test-server.R index a7e808237..7a227316a 100644 --- a/tests/testthat/test-test-server.R +++ b/tests/testthat/test-test-server.R @@ -413,11 +413,11 @@ test_that("captures ggplot2 outputs", { server <- function(input, output, session){ output$fixed <- renderPlot({ - ggplot2::qplot(iris$Sepal.Length, iris$Sepal.Width) + withr::with_namespace("ggplot2", { ggplot(iris) + geom_point(aes(Sepal.Length, Sepal.Width)) }) }, width=300, height=350) output$dynamic <- renderPlot({ - ggplot2::qplot(iris$Sepal.Length, iris$Sepal.Width) + withr::with_namespace("ggplot2", { ggplot(iris) + geom_point(aes(Sepal.Length, Sepal.Width)) }) }) }