Running ‘testthat.R’ [3s/39s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(nutrientr)
  > 
  > test_check("nutrientr")
  [ FAIL 25 | WARN 0 | SKIP 1 | PASS 1 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • No API key available (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-clean_data.R:8:3): Structure output is correct for food endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-clean_data.R:8:2
  ── Error (test-clean_data.R:20:3): Structure output is correct for nutrient amount endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-clean_data.R:20:2
  ── Error (test-clean_data.R:32:3): Structure output is correct for nutrient group endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("nutrientgroup", "664fbadd34e6c2ca75235709f9ede2bd") at test-clean_data.R:32:2
  ── Error (test-clean_data.R:45:3): Structure output is correct for nutrient name endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("nutrientname", "664fbadd34e6c2ca75235709f9ede2bd") at test-clean_data.R:45:2
  ── Error (test-clean_data.R:58:3): Structure output is correct for nutrient source endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("nutrientsource", "664fbadd34e6c2ca75235709f9ede2bd") at test-clean_data.R:58:2
  ── Error (test-clean_data.R:71:3): Structure output is correct for refuse amount endpoint endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-clean_data.R:71:2
  ── Error (test-clean_data.R:83:3): Structure output is correct for serving size endpoint endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-clean_data.R:83:2
  ── Error (test-clean_data.R:96:3): Structure output is correct for yield amount endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-clean_data.R:96:2
  ── Error (test-get_food.R:2:3): Structure output is correct for food endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_food(...) at test-get_food.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-get_nutrientamount.R:2:3): Structure output is correct for nutrient amount endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_nutrientamount(...) at test-get_nutrientamount.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-get_nutrientgroup.R:2:3): Structure output is correct for nutrient group endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_nutrientgroup(apiKey = "664fbadd34e6c2ca75235709f9ede2bd") at test-get_nutrientgroup.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-get_nutrientname.R:2:3): Structure output is correct for nutrient name endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_nutrientname(apiKey = "664fbadd34e6c2ca75235709f9ede2bd") at test-get_nutrientname.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-get_nutrientsource.R:2:3): Structure output is correct for nutrient source endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_nutrientsource(apiKey = "664fbadd34e6c2ca75235709f9ede2bd") at test-get_nutrientsource.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-get_refuseamount.R:2:3): Structure output is correct for refuse amount endpoint endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_refuseamount(...) at test-get_refuseamount.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-get_servingsize.R:2:3): Structure output is correct for serving size endpoint endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_servingsize(...) at test-get_servingsize.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-get_yieldamount.R:2:3): Structure output is correct for yield amount endpoint ──
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::get_yieldamount(...) at test-get_yieldamount.R:2:2
   2.   └─nutrientr::query_api(...)
  ── Error (test-query_api.R:2:3): food endpoint is reachable ────────────────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-query_api.R:2:2
  ── Error (test-query_api.R:7:3): nutrientamount endpoint is reachable ──────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-query_api.R:7:2
  ── Error (test-query_api.R:12:3): nutrientgroup is reachable ───────────────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api(...) at test-query_api.R:12:2
  ── Error (test-query_api.R:17:3): nutrientname endpoint is reachable ───────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("nutrientname", "664fbadd34e6c2ca75235709f9ede2bd") at test-query_api.R:17:2
  ── Error (test-query_api.R:22:3): nutrientsource endpoint is reachable ─────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("nutrientsource", "664fbadd34e6c2ca75235709f9ede2bd") at test-query_api.R:22:2
  ── Error (test-query_api.R:27:3): refuseamount endpoint is reachable ───────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("refuseamount", "664fbadd34e6c2ca75235709f9ede2bd") at test-query_api.R:27:2
  ── Error (test-query_api.R:32:3): servingsize endpoint is reachable ────────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("servingsize", "664fbadd34e6c2ca75235709f9ede2bd") at test-query_api.R:32:2
  ── Error (test-query_api.R:37:3): yieldamount endpoint is reachable ────────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("yieldamount", "664fbadd34e6c2ca75235709f9ede2bd") at test-query_api.R:37:2
  ── Error (test-query_api.R:42:3): Invalid endpoint will yield an error ─────────
  Error: Canadian Nutrient File API request failed: 503 <html>
  <head><title>503 Service Temporarily Unavailable</title></head>
  <body>
  <center><h1>503 Service Temporarily Unavailable</h1></center>
  <hr><center>openresty</center>
  </body>
  </html>
  
  Backtrace:
      ▆
   1. └─nutrientr::query_api("yieldamount", "664fbadd34e6c2ca75235709f9ede2bd") at test-query_api.R:42:2
  
  [ FAIL 25 | WARN 0 | SKIP 1 | PASS 1 ]
  Error: Test failures
  Execution halted