tests/testthat/test-ggplot-blank.R

test_that("geom_blank", {
  skip_if_not_installed("ggplot2", "3.4.0")
  qp <- expect_warning(qplot(), "deprecated")
  l <- ggplotly(qp)$x
  
  expect_length(l$data, 1)
  expect_false(l$data[[1]]$visible)
  
  l <- ggplotly(ggplot())$x
  
  expect_length(l$data, 1)
  expect_false(l$data[[1]]$visible)
  
})

Try the plotly package in your browser

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

plotly documentation built on May 29, 2024, 2:23 a.m.