Running ‘testthat.R’ [36s/56s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(mapme.biodiversity)
  > library(pbapply)
  > 
  > pboptions(type = "none")
  > test_check("mapme.biodiversity")
  Argument 'vers_treecover' for resource 'treecover2000' was not specified. Setting to default value of 'GFC-2020-v1.8'.
  Starting process to download resource 'treecover2000'........
  Skipping existing files in output directory.
  Creating dataset /home/hornik/tmp/R.check/r-patched-gcc/Work/build/Packages/mapme.biodiversity/res/treecover2000/tileindex_treecover2000.gpkg failed.
  Starting process to download resource 'srtmdem'........
  Argument 'range_traveltime' for resource 'traveltime' was not specified. Setting to default value of '20k_50k'.
  Starting process to download resource 'traveltime'........
  Starting process to download resource 'traveltime'........
  The selected range 'not-available' is not available ranges for traveltime Available ranges are 5k_10k, 10k_20k, 20k_50k, 50k_100k, 100k_200k, 200k_500k, 500k_1mio, 1mio_5mio, 50k_50mio, 5k_110mio, 20k_110mio.
  <simpleError in .get_traveltime_url(range_traveltime, filenames): No supoorted ranges have been specified.>
  <simpleWarning: Download for resource traveltime failed. Returning unmodified portfolio object.>
  Starting process to download resource 'traveltime'........
  The selected ranges 'not-available', 'not-available2' are not available ranges for traveltime Available ranges are 5k_10k, 10k_20k, 20k_50k, 50k_100k, 100k_200k, 200k_500k, 500k_1mio, 1mio_5mio, 50k_50mio, 5k_110mio, 20k_110mio.
  <simpleError in .get_traveltime_url(range_traveltime, filenames): No supoorted ranges have been specified.>
  <simpleWarning: Download for resource traveltime failed. Returning unmodified portfolio object.>
  Starting process to download resource 'traveltime'........
  The selected range 'not-available' is not available ranges for traveltime Available ranges are 5k_10k, 10k_20k, 20k_50k, 50k_100k, 100k_200k, 200k_500k, 500k_1mio, 1mio_5mio, 50k_50mio, 5k_110mio, 20k_110mio.
  Reduced to the available range of 20k_50k.
  Starting process to download resource 'greenhouse'........
  Starting process to download resource 'lossyear'........
  <simpleError: Wrong version specified for lossyear resource. Select one of GFC-2015-v1.3.Wrong version specified for lossyear resource. Select one of GFC-2016-v1.4.Wrong version specified for lossyear resource. Select one of GFC-2017-v1.5.Wrong version specified for lossyear resource. Select one of GFC-2018-v1.6.Wrong version specified for lossyear resource. Select one of GFC-2019-v1.7.Wrong version specified for lossyear resource. Select one of GFC-2020-v1.8.>
  <simpleWarning: Download for resource lossyear failed. Returning unmodified portfolio object.>
  Argument 'vers_lossyear' for resource 'lossyear' was not specified. Setting to default value of 'GFC-2020-v1.8'.
  Starting process to download resource 'lossyear'........
  Starting process to download resource 'treecover2000'........
  Skipping existing files in output directory.
  Creating dataset /home/hornik/tmp/R.check/r-patched-gcc/Work/build/Packages/mapme.biodiversity/res/treecover2000/tileindex_treecover2000.gpkg failed.
  Starting process to download resource 'treecover2000'........
  <simpleError: Wrong version specified for treecover resource. Select one of GFC-2015-v1.3, GFC-2016-v1.4, GFC-2017-v1.5, GFC-2018-v1.6, GFC-2019-v1.7, GFC-2020-v1.8.>
  <simpleWarning: Download for resource treecover2000 failed. Returning unmodified portfolio object.>
  Argument 'vers_treecover' for resource 'treecover2000' was not specified. Setting to default value of 'GFC-2020-v1.8'.
  Starting process to download resource 'treecover2000'........
  Starting process to download resource 'worldpop'........
  sh: 1: /no-valid-bin: not found
  Creating dataset /home/hornik/tmp/R.check/r-patched-gcc/Work/build/Packages/mapme.biodiversity/res/chirps/tileindex_chirps.gpkg failed.
  The following requested resource is already available: treecover2000.
  Argument 'vers_treecover' for resource 'treecover2000' was not specified. Setting to default value of 'GFC-2020-v1.8'.
  Some target years are not available for treecover.
  Some target years are not available for treecover.
  Checking URLs for existence. This may take a while...
  Checking URLs for existence. This may take a while...
  Skipping existing files in output directory.
  Checking URLs for existence. This may take a while...
  [ FAIL 3 | WARN 3 | SKIP 23 | PASS 102 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • On CRAN (23)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-calc_indicator.R:23:3): multiplication works ────────────────────
  <Rcpp::exception/C++Error/error/condition>
  Error in `CPL_write_ogr(obj, dsn, layer, driver, as.character(dataset_options), 
      as.character(layer_options), geom, dim, fids, config_options, 
      quiet, append, delete_dsn, delete_layer, write_geometries, 
      getOption("width"))`: Creation failed.
  
  Backtrace:
      ▆
   1. └─mapme.biodiversity::get_resources(...) at test-calc_indicator.R:23:2
   2.   └─mapme.biodiversity:::.get_single_resource(x, resource, ...)
   3.     └─sf::write_sf(footprints, dsn = tindex_file)
   4.       ├─sf::st_write(..., quiet = quiet, append = append, delete_layer = delete_layer)
   5.       └─sf:::st_write.sf(..., quiet = quiet, append = append, delete_layer = delete_layer)
   6.         └─sf:::CPL_write_ogr(...)
  ── Error (test-get_resources.R:31:3): get_resources works ──────────────────────
  <Rcpp::exception/C++Error/error/condition>
  Error in `CPL_write_ogr(obj, dsn, layer, driver, as.character(dataset_options), 
      as.character(layer_options), geom, dim, fids, config_options, 
      quiet, append, delete_dsn, delete_layer, write_geometries, 
      getOption("width"))`: Creation failed.
  
  Backtrace:
       ▆
    1. ├─testthat::expect_message(...) at test-get_resources.R:31:2
    2. │ └─testthat:::expect_condition_matching(...)
    3. │   └─testthat:::quasi_capture(...)
    4. │     ├─testthat .capture(...)
    5. │     │ └─base::withCallingHandlers(...)
    6. │     └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    7. └─mapme.biodiversity::get_resources(...)
    8.   └─mapme.biodiversity:::.get_single_resource(x, resource, ...)
    9.     └─sf::write_sf(footprints, dsn = tindex_file)
   10.       ├─sf::st_write(..., quiet = quiet, append = append, delete_layer = delete_layer)
   11.       └─sf:::st_write.sf(..., quiet = quiet, append = append, delete_layer = delete_layer)
   12.         └─sf:::CPL_write_ogr(...)
  ── Error (test-portfolio.R:119:3): init_portfolio works ────────────────────────
  <Rcpp::exception/C++Error/error/condition>
  Error in `CPL_write_ogr(obj, dsn, layer, driver, as.character(dataset_options), 
      as.character(layer_options), geom, dim, fids, config_options, 
      quiet, append, delete_dsn, delete_layer, write_geometries, 
      getOption("width"))`: Creation failed.
  
  Backtrace:
      ▆
   1. ├─... %>% get_resources("chirps") at test-portfolio.R:119:2
   2. └─mapme.biodiversity::get_resources(., "chirps")
   3.   └─mapme.biodiversity:::.get_single_resource(x, resource, ...)
   4.     └─sf::write_sf(footprints, dsn = tindex_file)
   5.       ├─sf::st_write(..., quiet = quiet, append = append, delete_layer = delete_layer)
   6.       └─sf:::st_write.sf(..., quiet = quiet, append = append, delete_layer = delete_layer)
   7.         └─sf:::CPL_write_ogr(...)
  
  [ FAIL 3 | WARN 3 | SKIP 23 | PASS 102 ]
  Error: Test failures
  Execution halted