Add more donttests to stay below 5s for each test
Change-Id: I4dde61ce4847f8c7067870256c14fe8998d18e0c
diff --git a/R/KorAPCorpusStats.R b/R/KorAPCorpusStats.R
index 55dbd15..8d9545a 100644
--- a/R/KorAPCorpusStats.R
+++ b/R/KorAPCorpusStats.R
@@ -26,7 +26,7 @@
#' @return \code{KorAPCorpusStats} object with the slots \code{documents}, \code{tokens}, \code{sentences}, \code{paragraphs}
#'
#' @examples
-#' corpusStats(new("KorAPConnection"))
+#' \donttest{corpusStats(new("KorAPConnection"))}
#'
#' kco <- new("KorAPConnection")
#' corpusStats(kco, "pubDate in 2017 & articleType=/Zeitung.*/")
diff --git a/R/KorAPQuery.R b/R/KorAPQuery.R
index d6137d1..b2926d7 100644
--- a/R/KorAPQuery.R
+++ b/R/KorAPQuery.R
@@ -101,7 +101,9 @@
#'
#' @examples
#' # Fetch metadata of every query hit for "Ameisenplage" and show a summary
+#' \donttest{
#' new("KorAPConnection") %>% corpusQuery("Ameisenplage") %>% fetchAll()
+#' }
#'
#' # Use the copy of a KorAP-web-frontend URL for an API query of "Ameise" in a virtual corpus
#' # and show the number of query hits (but don't fetch them).
@@ -228,8 +230,9 @@
#' @return The \code{kqo} input object with updated slots \code{collectedMatches}, \code{apiResponse}, \code{nextStartIndex}, \code{hasMoreMatches}
#'
#' @examples
-#' q <- new("KorAPConnection") %>% corpusQuery("Ameisenplage") %>% fetchNext()
+#' \donttest{q <- new("KorAPConnection") %>% corpusQuery("Ameisenplage") %>% fetchNext()
#' q@collectedMatches
+#' }
#'
#' @references
#' \url{https://ids-pub.bsz-bw.de/frontdoor/index/index/docId/9026}
diff --git a/R/highcharter-helper.R b/R/highcharter-helper.R
index 9e98114..c9c9ac1 100644
--- a/R/highcharter-helper.R
+++ b/R/highcharter-helper.R
@@ -11,9 +11,10 @@
#' @param ylabel defaults to \% if \code{as.alternatives} is \code{true} and to "ipm" otherwise.
#'
#' @examples
-#' \donttest{year <- c(1990:2018)}\dontshow{year <- c(2013:2014)}
+#' \donttest{year <- c(1990:2018)}\dontshow{year <- c(2013:2013)}
+#' \donttest{alternatives <- c("macht []{0,3} Sinn", "ergibt []{0,3} Sinn")}\dontshow{alternatives <- c("macht []{0,3} Sinn")}
#' new("KorAPConnection", verbose = TRUE) %>%
-#' frequencyQuery(query = c("macht []{0,3} Sinn", "ergibt []{0,3} Sinn"),
+#' frequencyQuery(query = alternatives,
#' vc = paste("textType = /Zeit.*/ & pubDate in", year),
#' as.alternatives = TRUE) %>%
#' hc_freq_by_year_ci(as.alternatives = TRUE)
diff --git a/R/misc.R b/R/misc.R
index fad39ad..75697d3 100644
--- a/R/misc.R
+++ b/R/misc.R
@@ -178,9 +178,9 @@
#' @examples
#' library(ggplot2)
#' kco <- new("KorAPConnection", verbose=TRUE)
-#' \donttest{year = (2003:2011)}\dontshow{year = c(2005)}
-#' g <- expand_grid(condition = c("textDomain = /Wirtschaft.*/", "textDomain != /Wirtschaft.*/"),
-#' year) %>%
+#' \donttest{year <- (2003:2011)}\dontshow{year <- c(2005)}
+#' \donttest{condition <- c("textDomain = /Wirtschaft.*/", "textDomain != /Wirtschaft.*/")}\dontshow{condition <- c("textDomain = /Wirtschaft.*/")}
+#' g <- expand_grid(condition, year) %>%
#' cbind(frequencyQuery(kco, "[tt/l=Heuschrecke]",
#' paste0(.$condition," & pubDate in ", .$year))) %>%
#' ipm() %>%