Running ‘testthat.R’
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(junr)
  > 
  > test_check("junr")
  1. Error: The connection to the test url gets a response (@test-getdata.R#11) --
  Unable to communicate securely with peer: requested domain name does not match the server's certificate.
  1: GET(paste(base_url, "?auth_key=", api_key, sep = ""), accept_json()) at testthat/test-getdata.R:11
  2: request_perform(req, hu$handle$handle)
  3: request_fetch(req$output, req$url, handle)
  4: request_fetch.write_memory(req$output, req$url, handle)
  5: curl::curl_fetch_memory(url, handle = handle)
  
  Error in curl::curl_fetch_memory(url, handle = handle) : 
    Unable to communicate securely with peer: requested domain name does not match the server's certificate.
  Error in curl::curl_fetch_memory(url, handle = handle) : 
    Unable to communicate securely with peer: requested domain name does not match the server's certificate.
  Error in content_index$guid : $ operator is invalid for atomic vectors
  Error in curl::curl_fetch_memory(url, handle = handle) : 
    Unable to communicate securely with peer: requested domain name does not match the server's certificate.
  Error in content_index$guid : $ operator is invalid for atomic vectors
  Error in curl::curl_fetch_memory(url, handle = handle) : 
    Illegal characters found in URL
  Error in curl::curl_fetch_memory(url, handle = handle) : 
    Unable to communicate securely with peer: requested domain name does not match the server's certificate.
  In addition: Warning messages:
  1: In doTryCatch(return(expr), name, parentenv, handler) :
    NAs introduced by coercion
  2: In doTryCatch(return(expr), name, parentenv, handler) :
    NAs introduced by coercion
  3: In doTryCatch(return(expr), name, parentenv, handler) :
    NAs introduced by coercion
  2. Failure: The test endpoint is still valid (@test-utils.R#11) ----------------
  nrow(currency_data) > 0 isn't true.
  
  
  3. Error: The test endpoint is still valid (@test-utils.R#12) ------------------
  $ operator is invalid for atomic vectors
  1: expect_true(!is.null(currency_data$`Monto Adjudicado`)) at testthat/test-utils.R:12
  2: expect(identical(as.vector(object), TRUE), sprintf("%s isn't true.", lab), info = info)
  3: as.expectation(exp, ..., srcref = srcref)
  4: identical(as.vector(object), TRUE)
  5: as.vector(object)
  
  4. Error: Currency values are converted to numeric (@test-utils.R#16) ----------
  $ operator is invalid for atomic vectors
  1: clean_currency(currency_data$`Monto Adjudicado`) at testthat/test-utils.R:16
  2: gsub(get_currency_character(currency_column[1], currency_symbol_pos), "", currency_column)
  
  testthat results ================================================================
  OK: 16 SKIPPED: 0 FAILED: 4
  1. Error: The connection to the test url gets a response (@test-getdata.R#11) 
  2. Failure: The test endpoint is still valid (@test-utils.R#11) 
  3. Error: The test endpoint is still valid (@test-utils.R#12) 
  4. Error: Currency values are converted to numeric (@test-utils.R#16) 
  
  Error: testthat unit tests failed
  Execution halted