diff --git a/tests/testthat/_snaps/geom/area.svg b/tests/testthat/_snaps/geom/area.svg
new file mode 100644
index 0000000..8423c45
--- /dev/null
+++ b/tests/testthat/_snaps/geom/area.svg
@@ -0,0 +1,84 @@
+
+
diff --git a/tests/testthat/_snaps/geom/histogram.svg b/tests/testthat/_snaps/geom/histogram.svg
new file mode 100644
index 0000000..c096a8f
--- /dev/null
+++ b/tests/testthat/_snaps/geom/histogram.svg
@@ -0,0 +1,185 @@
+
+
diff --git a/tests/testthat/test-geom.R b/tests/testthat/test-geom.R
index 424d9a3..052f5f5 100644
--- a/tests/testthat/test-geom.R
+++ b/tests/testthat/test-geom.R
@@ -4,6 +4,12 @@ test_that("geometry patterns work as expected", {
skip_if_not_installed("vdiffr")
library("vdiffr")
+ expect_doppelganger("area", {
+ huron <- data.frame(year = 1875:1972, level = as.vector(LakeHuron))
+ ggplot(huron, aes(year)) +
+ geom_area_pattern(aes(y = level))
+ })
+
expect_doppelganger("bar", {
ggplot(ggplot2::mpg, aes(class)) +
geom_bar_pattern(
@@ -109,6 +115,11 @@ test_that("geometry patterns work as expected", {
coord_fixed(ratio = 100)
})
+ expect_doppelganger("histogram", {
+ ggplot(diamonds, aes(carat)) +
+ geom_histogram_pattern(pattern = "stripe", bins = 30)
+ })
+
expect_doppelganger("polygon", {
angle <- seq(0, 2*pi, length.out = 7) + pi/6
polygon_df <- data.frame(