tests/testthat/test_interactive_annotate.R

test_that("interactive_annotate",
{
  skip_on_cran()
  inix <- 0
  iniy <- 0
  inidegrees <- 0
  inisize <- 10
  iniweight <- 400
  inikerning <- 0
  txt <- "hello"
  iniv <- list(location = geometry_point(inix, iniy), degrees = inidegrees, size = inisize, weight = iniweight, kerning = inikerning)
  expected <- image_annotate(img, txt, location = geometry_point(inix, iniy), degrees = inidegrees, size = inisize, weight = iniweight, kerning = inikerning)
  expect_equal(expected, interactive_annotate(img, txt))
  expect_equal(iniv, interactive_annotate(img, txt, return_param = TRUE))
  expect_equal(expected, interactive_annotate(img, txt, scale = scale1))
})

Try the magickGUI package in your browser

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

magickGUI documentation built on July 12, 2021, 5:06 p.m.