Running ‘testthat.R’
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(RAhrefs)
  > test_check("RAhrefs")
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Failure (test_auth.R:10:3): api_key param doesn't accept wrong values ───────
  `rah_auth(api_key = "stupid things", verbose = TRUE)` threw an error with unexpected message.
  Expected match: "Authorization error: HTTP status code"
  Actual message: "URL using bad/illegal format or missing URL"
  Backtrace:
       █
    1. ├─testthat::expect_error(...) test_auth.R:10:2
    2. │ └─testthat:::quasi_capture(...)
    3. │   ├─testthat:::.capture(...)
    4. │   │ └─base::withCallingHandlers(...)
    5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    6. └─RAhrefs::rah_auth(api_key = "stupid things", verbose = TRUE)
    7.   └─httr::GET(...)
    8.     └─httr:::request_perform(req, hu$handle$handle)
    9.       ├─httr:::request_fetch(req$output, req$url, handle)
   10.       └─httr:::request_fetch.write_memory(req$output, req$url, handle)
   11.         └─curl::curl_fetch_memory(url, handle = handle)
  ── Failure (test_auth.R:16:3): api_key param doesn't accept wrong values ───────
  `rah_auth(api_key = "stupid things", verbose = FALSE)` threw an error with unexpected message.
  Expected match: "Authorization error: HTTP status code"
  Actual message: "URL using bad/illegal format or missing URL"
  Backtrace:
       █
    1. ├─testthat::expect_error(...) test_auth.R:16:2
    2. │ └─testthat:::quasi_capture(...)
    3. │   ├─testthat:::.capture(...)
    4. │   │ └─base::withCallingHandlers(...)
    5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    6. └─RAhrefs::rah_auth(api_key = "stupid things", verbose = FALSE)
    7.   └─httr::GET(...)
    8.     └─httr:::request_perform(req, hu$handle$handle)
    9.       ├─httr:::request_fetch(req$output, req$url, handle)
   10.       └─httr:::request_fetch.write_memory(req$output, req$url, handle)
   11.         └─curl::curl_fetch_memory(url, handle = handle)
  
  [ FAIL 2 | WARN 0 | SKIP 0 | PASS 10 ]
  Error: Test failures
  Execution halted