Running 'testthat.R' [142s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(webTRISr)
  > 
  > testthat::test_check('webTRISr')
  -- 1. Error: WTares() returns dataframe (@test_WTareas.R#5)  -------------------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_areas() at testthat/test_WTareas.R:5
  2: parse_json(api(path = target_api))
  3: jsonlite::fromJSON(txt = httr::content(httrresp, "text"), simplifyVector = TRUE)
  4: httr::content(httrresp, "text")
  5: stopifnot(is.response(x))
  6: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  7: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  8: tryCatchList(expr, classes, parentenv, handlers)
  9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  10: value[[3L]](cond)
  
  -- 2. Error: WTares(3) returns dataframe (@test_WTareas.R#16)  -----------------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_areas(3) at testthat/test_WTareas.R:16
  2: parse_json(api(path = target_api))
  3: jsonlite::fromJSON(txt = httr::content(httrresp, "text"), simplifyVector = TRUE)
  4: httr::content(httrresp, "text")
  5: stopifnot(is.response(x))
  6: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  7: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  8: tryCatchList(expr, classes, parentenv, handlers)
  9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  10: value[[3L]](cond)
  
  -- 3. Error: webtris_quality() returns dataframe (@test_WTquality.R#5)  --------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_quality(siteID = "1", start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         daily = TRUE) at testthat/test_WTquality.R:5
  2: parse_json(api(path = path, query = query))
  3: jsonlite::fromJSON(txt = httr::content(httrresp, "text"), simplifyVector = TRUE)
  4: httr::content(httrresp, "text")
  5: stopifnot(is.response(x))
  6: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  7: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  8: tryCatchList(expr, classes, parentenv, handlers)
  9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  10: value[[3L]](cond)
  
  -- 4. Error: webtris_quality(daily=FALSE) returns dataframe (@test_WTquality.R#1
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_quality(siteID = c("1", "3"), start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         daily = FALSE) at testthat/test_WTquality.R:14
  2: parse_json(api(path = manual_path))
  3: jsonlite::fromJSON(txt = httr::content(httrresp, "text"), simplifyVector = TRUE)
  4: httr::content(httrresp, "text")
  5: stopifnot(is.response(x))
  6: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  7: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  8: tryCatchList(expr, classes, parentenv, handlers)
  9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  10: value[[3L]](cond)
  
  -- 5. Error: webtris_sites() returns dataframe (@test_WTsites.R#5)  ------------
  Timeout was reached: Connection timed out after 10016 milliseconds
  1: webtris_sites() at testthat/test_WTsites.R:5
  2: parse_json(api(path = target_api))
  3: jsonlite::fromJSON(txt = httr::content(httrresp, "text"), simplifyVector = TRUE)
  4: httr::content(httrresp, "text")
  5: stopifnot(is.response(x))
  6: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  7: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  8: tryCatchList(expr, classes, parentenv, handlers)
  9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  10: value[[3L]](cond)
  
  -- 6. Error: webtris_quality(daily=FALSE) returns dataframe (@test_WTsites.R#14)
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_sites(1) at testthat/test_WTsites.R:14
  2: parse_json(api(path = target_api))
  3: jsonlite::fromJSON(txt = httr::content(httrresp, "text"), simplifyVector = TRUE)
  4: httr::content(httrresp, "text")
  5: stopifnot(is.response(x))
  6: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  7: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  8: tryCatchList(expr, classes, parentenv, handlers)
  9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  10: value[[3L]](cond)
  
  -- 7. Error: Daily report works (@test_reports.R#5)  ---------------------------
  Timeout was reached: Connection timed out after 10000 milliseconds
  1: webTRISr::webtris_report("7", "01012017", "07012017", "daily", 100, TRUE, FALSE) at testthat/test_reports.R:5
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  -- 8. Error: This report should have 576 rows (@test_reports.R#20)  ------------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webTRISr::webtris_report(c("51", "2", "5"), "01012017", "02012017", "daily", 10000) at testthat/test_reports.R:20
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  -- 9. Error: Report annual-totals works (@test_reports.R#27)  ------------------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_report(sites = c("7", "26"), start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         report_type = "monthly-daily") at testthat/test_reports.R:27
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  -- 10. Error: Report annual-monthly works (@test_reports.R#38)  ----------------
  Timeout was reached: Connection timed out after 10000 milliseconds
  1: webtris_report(sites = c("7", "26"), start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         report_type = "annual-monthly") at testthat/test_reports.R:38
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  -- 11. Error: Report monthly-summary works (@test_reports.R#48)  ---------------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_report(sites = c("7", "26"), start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         report_type = "monthly-summary") at testthat/test_reports.R:48
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  -- 12. Error: Report monthly-daily works (@test_reports.R#58)  -----------------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_report(sites = c("7", "26"), start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         report_type = "monthly-daily") at testthat/test_reports.R:58
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  -- 13. Error: Report monthly-daily-aggregate works (@test_reports.R#68)  -------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_report(sites = c("7", "26"), start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         report_type = "monthly-daily-aggregate") at testthat/test_reports.R:68
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  -- 14. Error: Report monthly-hourly-aggregate works (@test_reports.R#78)  ------
  Timeout was reached: Connection timed out after 10015 milliseconds
  1: webtris_report(sites = c("7", "26"), start_date = "01-01-2017", lubridate::dmy("07-01-2017"), 
         report_type = "monthly-hourly-aggregate") at testthat/test_reports.R:78
  2: reportFetch(sites, start_date, end_date, report_type = report_to_fetch, maxrequest, 
         verbose)
  3: reportAPI(sites, start_date, end_date, report_type, maxrequest, currentpage, verbose)
  4: api(verbose, path = api_target, query = varlist)
  5: httr::GET(api_url)
  6: request_perform(req, hu$handle$handle)
  7: request_fetch(req$output, req$url, handle)
  8: request_fetch.write_memory(req$output, req$url, handle)
  9: curl::curl_fetch_memory(url, handle = handle)
  
  == testthat results  ===========================================================
  OK: 0 SKIPPED: 0 FAILED: 14
  1. Error: WTares() returns dataframe (@test_WTareas.R#5) 
  2. Error: WTares(3) returns dataframe (@test_WTareas.R#16) 
  3. Error: webtris_quality() returns dataframe (@test_WTquality.R#5) 
  4. Error: webtris_quality(daily=FALSE) returns dataframe (@test_WTquality.R#14) 
  5. Error: webtris_sites() returns dataframe (@test_WTsites.R#5) 
  6. Error: webtris_quality(daily=FALSE) returns dataframe (@test_WTsites.R#14) 
  7. Error: Daily report works (@test_reports.R#5) 
  8. Error: This report should have 576 rows (@test_reports.R#20) 
  9. Error: Report annual-totals works (@test_reports.R#27) 
  1. ...
  
  Error: testthat unit tests failed
  Execution halted