diff --git a/DESCRIPTION b/DESCRIPTION index 0b35faf6..1da341f8 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -18,14 +18,14 @@ Imports: httr (>= 0.5), lifecycle (>= 1.0.3), magrittr, - rlang (>= 1.0.0), + rlang (>= 1.1.0), selectr, tibble, - withr, xml2 (>= 1.3) Suggests: covr, knitr, + R6, readr, repurrrsive, rmarkdown, @@ -37,7 +37,8 @@ VignetteBuilder: knitr Config/Needs/website: tidyverse/tidytemplate Config/testthat/edition: 3 +Config/testthat/parallel: true Encoding: UTF-8 Language: en-US Roxygen: list(markdown = TRUE) -RoxygenNote: 7.2.3 +RoxygenNote: 7.3.0 diff --git a/R/encoding.R b/R/encoding.R index 19adf75f..8e265a0e 100644 --- a/R/encoding.R +++ b/R/encoding.R @@ -57,7 +57,7 @@ repair_encoding <- function(x, from = NULL) { from <- best_guess$encoding conf <- best_guess$confidence * 100 if (conf < 50) { - stop("No guess has more than 50% confidence", call. = FALSE) + cli::cli_abort("No guess has more than 50% confidence") } inform(paste0("Best guess: ", from, " (", conf, "% confident)")) diff --git a/R/form.R b/R/form.R index 1bd0b718..d39f81f3 100644 --- a/R/form.R +++ b/R/form.R @@ -47,7 +47,10 @@ html_form.xml_nodeset <- function(x, base_url = NULL) { #' @export html_form.xml_node <- function(x, base_url = NULL) { - stopifnot(xml2::xml_name(x) == "form") + if (xml2::xml_name(x) != "form") { + cli::cli_abort("{.arg x} must be a