diff --git a/tests/testthat/test-ggmap.R b/tests/testthat/test-ggmap.R index 82d1376..b6795e2 100644 --- a/tests/testthat/test-ggmap.R +++ b/tests/testthat/test-ggmap.R @@ -3,7 +3,7 @@ source("util.R") test_that("ggmap example works", { map <- getFakeMap() - ggmap(map) + print(ggmap(map)) expect_true(TRUE) # didn't stop: good! }) @@ -12,7 +12,7 @@ test_that("ggmapplot example works", { expect_warning( # deprecated, and uses deprecated syntax # warns twice - ggmapplot(map) + print(ggmapplot(map)) ) expect_true(TRUE) # didn't stop: good! }) diff --git a/tests/testthat/util.R b/tests/testthat/util.R index 5067ee3..d26aca1 100644 --- a/tests/testthat/util.R +++ b/tests/testthat/util.R @@ -1,5 +1,5 @@ getFakeMap <- function() { - map <- character() + map <- matrix("#000000") class(map) <- c('ggmap','raster') attr(map, "source") <- "osm" attr(map, "maptype") <- "openstreetmap" @@ -9,4 +9,4 @@ getFakeMap <- function() { ur.lat = 3, ur.lon = 4 ) map -} \ No newline at end of file +}