diff --git a/R/vis_miss.R b/R/vis_miss.R index 8a6bac92..8c79c165 100644 --- a/R/vis_miss.R +++ b/R/vis_miss.R @@ -72,7 +72,7 @@ vis_miss <- function(x, d <- x.na[row_order_index , ] %>% as.data.frame %>% - dplyr::mutate_(rows = ~ row_number()) %>% + dplyr::mutate_(rows = ~ dplyr::row_number()) %>% # gather the variables together for plotting # here we now have a column of the row number (row), # then the variable(variables), diff --git a/tests/testthat/test-ncdc_plot.r b/tests/testthat/test-ncdc_plot.r index 7caa6b79..ee88d2d9 100644 --- a/tests/testthat/test-ncdc_plot.r +++ b/tests/testthat/test-ncdc_plot.r @@ -11,6 +11,7 @@ test_that("ncdc_plot returns the correct class", { p <- ncdc_plot(out) expect_is(p, "ggplot") - expect_is(p$mapping$x, "name") + expect_is(p$mapping$x, "quosure") + expect_is(p$mapping$x, "formula") expect_named(p$mapping, c("x", "y")) }) diff --git a/tests/testthat/test-vis_miss.R b/tests/testthat/test-vis_miss.R index 072810fa..1bcdd7f7 100644 --- a/tests/testthat/test-vis_miss.R +++ b/tests/testthat/test-vis_miss.R @@ -1,6 +1,6 @@ context("vis_miss") -test_that("Valid ggplot object is produed",{ +test_that("Valid ggplot object is produced",{ monitors <- c("ASN00003003", "ASM00094299") weather_df <- meteo_pull_monitors(monitors) out <- vis_miss(weather_df)