- using R version 4.4.3 (2025-02-28 ucrt)
- using platform: x86_64-w64-mingw32
- R was compiled by
gcc.exe (GCC) 13.3.0
GNU Fortran (GCC) 13.3.0
- running under: Windows Server 2022 x64 (build 20348)
- using session charset: UTF-8
- checking for file 'MexicoDataAPI/DESCRIPTION' ... OK
- checking extension type ... Package
- this is package 'MexicoDataAPI' version '0.2.0'
- package encoding: UTF-8
- checking package namespace information ... OK
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking if there is a namespace ... OK
- checking for hidden files and directories ... OK
- checking for portable file names ... OK
- checking whether package 'MexicoDataAPI' can be installed ... OK
See the install log for details.
- checking installed package size ... OK
- checking package directory ... OK
- checking 'build' directory ... OK
- checking DESCRIPTION meta-information ... OK
- checking top-level files ... OK
- checking for left-over files ... OK
- checking index information ... OK
- checking package subdirectories ... OK
- checking code files for non-ASCII characters ... OK
- checking R files for syntax errors ... OK
- checking whether the package can be loaded ... [2s] OK
- checking whether the package can be loaded with stated dependencies ... [1s] OK
- checking whether the package can be unloaded cleanly ... [1s] OK
- checking whether the namespace can be loaded with stated dependencies ... [1s] OK
- checking whether the namespace can be unloaded cleanly ... [2s] OK
- checking loading without being on the library search path ... [2s] OK
- checking use of S3 registration ... OK
- checking dependencies in R code ... OK
- checking S3 generic/method consistency ... OK
- checking replacement functions ... OK
- checking foreign function calls ... OK
- checking R code for possible problems ... [5s] OK
- checking Rd files ... [1s] OK
- checking Rd metadata ... OK
- checking Rd cross-references ... OK
- checking for missing documentation entries ... OK
- checking for code/documentation mismatches ... OK
- checking Rd \usage sections ... OK
- checking Rd contents ... OK
- checking for unstated dependencies in examples ... OK
- checking contents of 'data' directory ... OK
- checking data for non-ASCII characters ... [0s] OK
- checking data for ASCII and uncompressed saves ... OK
- checking installed files from 'inst/doc' ... OK
- checking files in 'vignettes' ... OK
- checking examples ... [3s] OK
- checking for unstated dependencies in 'tests' ... OK
- checking tests ... [19s] ERROR
Running 'testthat.R' [19s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
> # This file is part of the standard setup for testthat.
> # It is recommended that you do not modify it.
> #
> # Where should you do additional test configuration?
> # Learn more about the roles of various files in:
> # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview
> # * https://testthat.r-lib.org/articles/special-files.html
>
> library(testthat)
> library(MexicoDataAPI)
>
> test_check("MexicoDataAPI")
Saving _problems/test-get_country_info_mx-24.R
API request failed.
Saving _problems/test-get_country_info_mx-47.R
Saving _problems/test-get_country_info_mx-48.R
Saving _problems/test-get_country_info_mx-49.R
Saving _problems/test-get_country_info_mx-50.R
Datasets available in the 'MexicoDataAPI' package:
Datasets available in the 'MexicoDataAPI' package:
[ FAIL 5 | WARN 0 | SKIP 22 | PASS 149 ]
══ Skipped tests (22) ══════════════════════════════════════════════════════════
• On CRAN (22): 'test-get_mexico_cpi.R:24:3', 'test-get_mexico_cpi.R:52:3',
'test-get_mexico_gdp.R:24:3', 'test-get_mexico_life_expectancy.R:24:3',
'test-get_mexico_life_expectancy.R:40:3',
'test-get_mexico_life_expectancy.R:50:3',
'test-get_mexico_literacy_rate.R:24:3',
'test-get_mexico_literacy_rate.R:44:3',
'test-get_mexico_literacy_rate.R:51:3',
'test-get_mexico_literacy_rate.R:58:3', 'test-get_mexico_population.R:25:3',
'test-get_mexico_population.R:46:3', 'test-get_mexico_population.R:53:3',
'test-get_mexico_population.R:60:3', 'test-get_mexico_population.R:67:3',
'test-get_mexico_population.R:75:3', 'test-get_mexico_unemployment.R:24:3',
'test-get_mexico_unemployment.R:44:3', 'test-get_mexico_unemployment.R:51:3',
'test-get_mexico_unemployment.R:58:3', 'test-get_mexico_unemployment.R:65:3',
'test-get_mexico_unemployment.R:73:3'
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test-get_country_info_mx.R:24:3'): get_country_info_mx() returns a tibble with correct structure ──
<curl_error_operation_timedout/curl_error/error/condition>
Error in `curl::curl_fetch_memory(url, handle = handle)`: Timeout was reached [restcountries.com]:
Connection timed out after 10011 milliseconds
Backtrace:
▆
1. ├─MexicoDataAPI::get_country_info_mx() at test-get_country_info_mx.R:24:3
2. │ └─httr::GET(url)
3. │ └─httr:::request_perform(req, hu$handle$handle)
4. │ ├─httr:::request_fetch(req$output, req$url, handle)
5. │ └─httr:::request_fetch.write_memory(req$output, req$url, handle)
6. │ └─curl::curl_fetch_memory(url, handle = handle)
7. └─curl:::raise_libcurl_error(...)
── Failure ('test-get_country_info_mx.R:47:3'): get_country_info_mx() returns data for Mexico ──
Expected `result$name_common` to equal "Mexico".
Differences:
`actual` is NULL
`expected` is a character vector ('Mexico')
── Failure ('test-get_country_info_mx.R:48:3'): get_country_info_mx() returns data for Mexico ──
Expected `result$capital` to equal "Mexico City".
Differences:
`actual` is NULL
`expected` is a character vector ('Mexico City')
── Failure ('test-get_country_info_mx.R:49:3'): get_country_info_mx() returns data for Mexico ──
Expected `result$region` to equal "Americas".
Differences:
`actual` is NULL
`expected` is a character vector ('Americas')
── Failure ('test-get_country_info_mx.R:50:3'): get_country_info_mx() returns data for Mexico ──
Expected `result$subregion` to equal "North America".
Differences:
`actual` is NULL
`expected` is a character vector ('North America')
[ FAIL 5 | WARN 0 | SKIP 22 | PASS 149 ]
Error:
! Test failures.
Execution halted
- checking for unstated dependencies in vignettes ... OK
- checking package vignettes ... OK
- checking re-building of vignette outputs ... [5s] OK
- checking PDF version of manual ... [19s] OK
- checking HTML version of manual ... [4s] OK
- DONE
Status: 1 ERROR