Running ‘testthat.R’ [11s/20s]
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(rnpn)
  > 
  > test_check("rnpn")
  Downloading...
  Downloading...
  Downloading...
  [ FAIL 21 | WARN 0 | SKIP 19 | PASS 11 ]
  
  ══ Skipped tests (19) ══════════════════════════════════════════════════════════
  • On CRAN (19): 'test-npn-geoserver.R:4:3', 'test-npn-geoserver.R:16:3',
    'test-npn-geoserver.R:41:3', 'test-npn-geoserver.R:81:3',
    'test-npn-geoserver.R:105:3', 'test-npn-geoserver.R:127:3',
    'test-npn-geoserver.R:146:3', 'test-npn-observations.R:8:3',
    'test-npn-observations.R:183:3', 'test-npn-observations.R:224:3',
    'test-npn-observations.R:268:3', 'test-npn-observations.R:333:3',
    'test-npn-observations.R:401:3', 'test-npn-observations.R:470:3',
    'test-npn-observations.R:539:3', 'test-npn-observations.R:593:3',
    'test-npn-observations.R:645:3', 'test-npn-observations.R:731:3',
    'test-npn-observations.R:840:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-npn-datasets.R:5:5'): datasets endpoint working ────────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-datasets.R:4:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_datasets() at test-npn-datasets.R:5:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-get-species.R:5:5'): npn_species returns a data frame ──────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-get-species.R:4:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_species() at test-npn-get-species.R:5:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-get-species.R:19:5'): npn_species_id working ───────────────
  Error in `httr2::resp_body_json(x, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
       ▆
    1. ├─vcr::use_cassette(...) at test-npn-get-species.R:18:3
    2. │ └─cassette$call_block(...)
    3. ├─rnpn::npn_species_id(3) at test-npn-get-species.R:19:5
    4. │ └─base::lapply(...)
    5. │   └─rnpn (local) FUN(X[[i]], ...)
    6. │     ├─httr2::resp_body_json(x, simplifyVector = TRUE) %>% tibble::as_tibble()
    7. │     └─httr2::resp_body_json(x, simplifyVector = TRUE)
    8. │       └─httr2::resp_check_content_type(...)
    9. │         └─httr2:::check_content_type(...)
   10. │           └─cli::cli_abort(...)
   11. │             └─rlang::abort(...)
   12. └─tibble::as_tibble(.)
  ── Error ('test-npn-get-species.R:30:5'): npn_species_state works ──────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-get-species.R:29:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_species_state("AZ") at test-npn-get-species.R:30:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-get-species.R:55:5'): npn_species_search works ─────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-get-species.R:54:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_species_search(start_date = "2023-01-01", end_date = "2023-05-15") at test-npn-get-species.R:55:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-get-species.R:81:5'): npn_species_types ────────────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-get-species.R:80:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_species_types() at test-npn-get-species.R:81:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-observations.R:18:5'): npn_download_status_data() works ────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
       ▆
    1. ├─vcr::use_cassette(...) at test-npn-observations.R:17:3
    2. │ └─cassette$call_block(...)
    3. ├─rnpn::npn_download_status_data(...) at test-npn-observations.R:18:5
    4. │ └─rnpn:::npn_get_data_by_year(...)
    5. │   └─rnpn:::npn_get_data(...)
    6. │     ├─httr2::resp_body_json(resp, simplifyVector = TRUE) %>% ...
    7. │     └─httr2::resp_body_json(resp, simplifyVector = TRUE)
    8. │       └─httr2::resp_check_content_type(...)
    9. │         └─httr2:::check_content_type(...)
   10. │           └─cli::cli_abort(...)
   11. │             └─rlang::abort(...)
   12. ├─rnpn (local) wrangle_dl_data(.)
   13. │ └─... %>% ...
   14. ├─dplyr::mutate(...)
   15. ├─dplyr::mutate(...)
   16. └─dplyr::mutate(...)
  ── Error ('test-npn-observations.R:52:5'): phenometrics downloads work ─────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
       ▆
    1. ├─vcr::use_cassette(...) at test-npn-observations.R:51:3
    2. │ └─cassette$call_block(...)
    3. ├─rnpn::npn_download_individual_phenometrics(...) at test-npn-observations.R:52:5
    4. │ └─rnpn:::npn_get_data_by_year(...)
    5. │   └─rnpn:::npn_get_data(...)
    6. │     ├─httr2::resp_body_json(resp, simplifyVector = TRUE) %>% ...
    7. │     └─httr2::resp_body_json(resp, simplifyVector = TRUE)
    8. │       └─httr2::resp_check_content_type(...)
    9. │         └─httr2:::check_content_type(...)
   10. │           └─cli::cli_abort(...)
   11. │             └─rlang::abort(...)
   12. ├─rnpn (local) wrangle_dl_data(.)
   13. │ └─... %>% ...
   14. ├─dplyr::mutate(...)
   15. ├─dplyr::mutate(...)
   16. └─dplyr::mutate(...)
  ── Error ('test-npn-observations.R:139:5'): custom period works ────────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
       ▆
    1. ├─vcr::use_cassette(...) at test-npn-observations.R:138:3
    2. │ └─cassette$call_block(...)
    3. ├─rnpn::npn_download_individual_phenometrics(...) at test-npn-observations.R:139:5
    4. │ └─rnpn:::npn_get_data_by_year(...)
    5. │   └─rnpn:::npn_get_data(...)
    6. │     ├─httr2::resp_body_json(resp, simplifyVector = TRUE) %>% ...
    7. │     └─httr2::resp_body_json(resp, simplifyVector = TRUE)
    8. │       └─httr2::resp_check_content_type(...)
    9. │         └─httr2:::check_content_type(...)
   10. │           └─cli::cli_abort(...)
   11. │             └─rlang::abort(...)
   12. ├─rnpn (local) wrangle_dl_data(.)
   13. │ └─... %>% ...
   14. ├─dplyr::mutate(...)
   15. ├─dplyr::mutate(...)
   16. └─dplyr::mutate(...)
  ── Error ('test-npn-partners.R:5:5'): npn_groups works ─────────────────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = !use_hierarchy)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-partners.R:4:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_groups() at test-npn-partners.R:5:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = !use_hierarchy)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-phenophases.R:5:5'): npn_phenophases works ─────────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-phenophases.R:4:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_phenophases() at test-npn-phenophases.R:5:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-phenophases.R:19:5'): npn_phenophase_definitions works ─────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-phenophases.R:18:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_phenophase_definitions() at test-npn-phenophases.R:19:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-phenophases.R:32:5'): npn_phenophase_details works ─────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-phenophases.R:31:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_phenophase_details(56) at test-npn-phenophases.R:32:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-phenophases.R:53:5'): npn_phenophases_by_species works ─────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-phenophases.R:52:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_phenophases_by_species(species_ids = 3, date = "2018-05-05") at test-npn-phenophases.R:53:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-phenophases.R:64:5'): npn_pheno_classes works ──────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-phenophases.R:63:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_pheno_classes() at test-npn-phenophases.R:64:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-phenophases.R:76:5'): npn_abundance_categories works ───────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-phenophases.R:75:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_abundance_categories() at test-npn-phenophases.R:76:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-phenophases.R:88:5'): npn_get_phenophases_for_taxon works ──
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-phenophases.R:87:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_get_phenophases_for_taxon(class_ids = 5, date = "2018-05-05") at test-npn-phenophases.R:88:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-stations.R:5:5'): npn_stations functions ───────────────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-stations.R:4:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_stations() at test-npn-stations.R:5:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-stations.R:28:4'): npn_stations_by_state functions ─────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-stations.R:27:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_stations_by_state() at test-npn-stations.R:28:4
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  ── Error ('test-npn-stations.R:41:5'): npn_stations_by_location functions ──────
  Error in `httr2::resp_body_json(., simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
       ▆
    1. ├─vcr::use_cassette(...) at test-npn-stations.R:40:3
    2. │ └─cassette$call_block(...)
    3. ├─rnpn::npn_stations_by_location(wkt = "POLYGON((-110.94484396954107 32.23623109416672,-110.96166678448247 32.23594069208043,-110.95960684795904 32.21328646993733,-110.94244071026372 32.21343170728929,-110.93935080547857 32.23216538049456,-110.94484396954107 32.23623109416672))") at test-npn-stations.R:41:5
    4. │ └─... %>% tibble::as_tibble()
    5. ├─tibble::as_tibble(.)
    6. └─httr2::resp_body_json(., simplifyVector = TRUE)
    7.   └─httr2::resp_check_content_type(...)
    8.     └─httr2:::check_content_type(...)
    9.       └─cli::cli_abort(...)
   10.         └─rlang::abort(...)
  ── Error ('test-npn-stations.R:55:5'): npn_stations_with_spp functions ─────────
  Error in `httr2::resp_body_json(resp, simplifyVector = TRUE)`: Unexpected content type "NA".
  * Expecting type "application/json" or suffix "json".
  Backtrace:
      ▆
   1. ├─vcr::use_cassette(...) at test-npn-stations.R:54:3
   2. │ └─cassette$call_block(...)
   3. └─rnpn::npn_stations_with_spp(100) at test-npn-stations.R:55:5
   4.   └─httr2::resp_body_json(resp, simplifyVector = TRUE)
   5.     └─httr2::resp_check_content_type(...)
   6.       └─httr2:::check_content_type(...)
   7.         └─cli::cli_abort(...)
   8.           └─rlang::abort(...)
  
  [ FAIL 21 | WARN 0 | SKIP 19 | PASS 11 ]
  Error: Test failures
  Execution halted