* using log directory 'd:/Rcompile/CRANpkg/local/4.3/dhis2r.Rcheck' * using R version 4.3.3 (2024-02-29 ucrt) * using platform: x86_64-w64-mingw32 (64-bit) * R was compiled by gcc.exe (GCC) 12.3.0 GNU Fortran (GCC) 12.3.0 * running under: Windows Server 2022 x64 (build 20348) * using session charset: UTF-8 * checking for file 'dhis2r/DESCRIPTION' ... OK * this is package 'dhis2r' version '0.1.1' * 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 'dhis2r' can be installed ... OK * 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 R files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... [1s] 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 ... [1s] OK * checking loading without being on the library search path ... [1s] 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 ... [4s] 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 LazyData ... OK * checking data for ASCII and uncompressed saves ... OK * checking installed files from 'inst/doc' ... OK * checking files in 'vignettes' ... OK * checking examples ... [2s] OK * checking for unstated dependencies in 'tests' ... OK * checking tests ... [4s] ERROR Running 'testthat.R' [4s] Running the tests in 'tests/testthat.R' failed. Complete output: > library(testthat) > library(dhis2r) > > test_check("dhis2r") [ FAIL 4 | WARN 0 | SKIP 0 | PASS 2 ] ══ Failed tests ════════════════════════════════════════════════════════════════ ── Error ('test-connect.R:16:3'): user information is a charater vector ──────── Error in `resp_body_json(reponse, simplifyVector = TRUE)`: Unexpected content type "text/html". • Expecting type "application/json" or suffix "json". Backtrace: ▆ 1. ├─testthat::expect_equal(...) at test-connect.R:16:3 2. │ └─testthat::quasi_label(enquo(object), label, arg = "object") 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. └─dhis2_play_connection$get_user_info() 5. └─httr2::resp_body_json(reponse, simplifyVector = TRUE) 6. └─httr2::resp_check_content_type(...) 7. └─httr2:::check_content_type(...) 8. └─cli::cli_abort(...) 9. └─rlang::abort(...) ── Error ('test-connect.R:21:3'): Resource(s) "displayName","singular","plural","href" are return ── Error in `resp_body_json(reponse, simplifyVector = TRUE)`: Unexpected content type "text/html". • Expecting type "application/json" or suffix "json". Backtrace: ▆ 1. ├─testthat::expect_equal(...) at test-connect.R:21:3 2. │ └─testthat::quasi_label(enquo(object), label, arg = "object") 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. └─dhis2_play_connection$get_metadata() 5. └─httr2::resp_body_json(reponse, simplifyVector = TRUE) 6. └─httr2::resp_check_content_type(...) 7. └─httr2:::check_content_type(...) 8. └─cli::cli_abort(...) 9. └─rlang::abort(...) ── Error ('test-connect.R:26:3'): Type of result of a specific resouce is list ── Error in `resp_body_json(reponse, simplifyVector = TRUE)`: Unexpected content type "text/html". • Expecting type "application/json" or suffix "json". Backtrace: ▆ 1. ├─testthat::expect_type(...) at test-connect.R:26:3 2. │ └─testthat::quasi_label(enquo(object), arg = "object") 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. └─dhis2_play_connection$get_metadata(endpoint = "dataElements") 5. └─httr2::resp_body_json(reponse, simplifyVector = TRUE) 6. └─httr2::resp_check_content_type(...) 7. └─httr2:::check_content_type(...) 8. └─cli::cli_abort(...) 9. └─rlang::abort(...) ── Error ('test-connect.R:32:3'): Type of result of possible fields is a character vector ── Error in `resp_body_json(reponse, simplifyVector = TRUE)`: Unexpected content type "text/html". • Expecting type "application/json" or suffix "json". Backtrace: ▆ 1. ├─testthat::expect_type(...) at test-connect.R:32:3 2. │ └─testthat::quasi_label(enquo(object), arg = "object") 3. │ └─rlang::eval_bare(expr, quo_get_env(quo)) 4. └─dhis2_play_connection$get_metadata_fields(endpoint = "dataElements") 5. └─httr2::resp_body_json(reponse, simplifyVector = TRUE) 6. └─httr2::resp_check_content_type(...) 7. └─httr2:::check_content_type(...) 8. └─cli::cli_abort(...) 9. └─rlang::abort(...) [ FAIL 4 | WARN 0 | SKIP 0 | PASS 2 ] Error: Test failures Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes in 'inst/doc' ... OK * checking re-building of vignette outputs ... [3s] ERROR Error(s) in re-building vignettes: --- re-building 'dhis2r.Rmd' using rmarkdown Quitting from lines at lines 35-37 [unnamed-chunk-3] (dhis2r.Rmd) Error: processing vignette 'dhis2r.Rmd' failed with diagnostics: Unexpected content type "text/html". • Expecting type "application/json" or suffix "json". --- failed re-building 'dhis2r.Rmd' SUMMARY: processing the following file failed: 'dhis2r.Rmd' Error: Vignette re-building failed. Execution halted * checking PDF version of manual ... [17s] OK * checking HTML version of manual ... [1s] OK * DONE Status: 2 ERRORs