Running ‘test-all.R’ [3s/20s]
Running the tests in ‘tests/test-all.R’ failed.
Complete output:
  > library(testthat)
  > library("rinat")
  > test_check("rinat")
  ── 1. Failure: Check all search parameters (@test-all.R#6)  ────────────────────
  "Ambystoma maculatum" does not match "Ambystoma 'unisexual complex'".
  Actual value: "Ambystoma maculatum"
  
  ── 2. Error: Check all search parameters (@test-all.R#17)  ─────────────────────
  argument is of length zero
  1: expect_equal(dim(get_inat_obs(query = "Mule Deer", bounds = bounds, maxresults = 10))[1], 
         10) at testthat/test-all.R:17
  2: quasi_label(enquo(object), label, arg = "object")
  3: eval_bare(get_expr(quo), get_env(quo))
  4: get_inat_obs(query = "Mule Deer", bounds = bounds, maxresults = 10)
  5: inat_handle(data)
  
  ── 3. Error: Check that getting observation by ID works (@test-all.R#23)  ──────
  lexical error: invalid char in json text.
                                         <?xml version="1.0" encoding="u
                       (right here) ------^
  1: expect_gt(length(get_inat_obs_id(res_set$id[1])), 0) at testthat/test-all.R:23
  2: quasi_label(enquo(object), label, arg = "object")
  3: eval_bare(get_expr(quo), get_env(quo))
  4: get_inat_obs_id(res_set$id[1])
  5: fromJSON(content(GET(base_url, path = q_path), as = "text"))
  6: parse_and_simplify(txt = txt, simplifyVector = simplifyVector, simplifyDataFrame = simplifyDataFrame, 
         simplifyMatrix = simplifyMatrix, flatten = flatten, ...)
  7: parseJSON(txt, bigint_as_char)
  8: parse_string(txt, bigint_as_char)
  
  164  Records
  0164  Records
  0── 4. Error: Check that taxon stats works (@test-all.R#37)  ────────────────────
  lexical error: invalid char in json text.
                                         <?xml version="1.0" encoding="u
                       (right here) ------^
  1: expect_gt(get_inat_taxon_stats(date = "2010-06-14")$total, 0) at testthat/test-all.R:37
  2: quasi_label(enquo(object), label, arg = "object")
  3: eval_bare(get_expr(quo), get_env(quo))
  4: get_inat_taxon_stats(date = "2010-06-14")
  5: fromJSON(content(GET(base_url, path = q_path, query = search), as = "text"))
  6: parse_and_simplify(txt = txt, simplifyVector = simplifyVector, simplifyDataFrame = simplifyDataFrame, 
         simplifyMatrix = simplifyMatrix, flatten = flatten, ...)
  7: parseJSON(txt, bigint_as_char)
  8: parse_string(txt, bigint_as_char)
  
  ── 5. Error: Check that user stats works (@test-all.R#41)  ─────────────────────
  lexical error: invalid char in json text.
                                         <?xml version="1.0" encoding="u
                       (right here) ------^
  1: expect_gt(get_inat_user_stats(date = "2010-06-14")$total, 0) at testthat/test-all.R:41
  2: quasi_label(enquo(object), label, arg = "object")
  3: eval_bare(get_expr(quo), get_env(quo))
  4: get_inat_user_stats(date = "2010-06-14")
  5: fromJSON(content(GET(base_url, path = q_path, query = search), as = "text"))
  6: parse_and_simplify(txt = txt, simplifyVector = simplifyVector, simplifyDataFrame = simplifyDataFrame, 
         simplifyMatrix = simplifyMatrix, flatten = flatten, ...)
  7: parseJSON(txt, bigint_as_char)
  8: parse_string(txt, bigint_as_char)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  [ OK: 11 | SKIPPED: 0 | WARNINGS: 0 | FAILED: 5 ]
  1. Failure: Check all search parameters (@test-all.R#6) 
  2. Error: Check all search parameters (@test-all.R#17) 
  3. Error: Check that getting observation by ID works (@test-all.R#23) 
  4. Error: Check that taxon stats works (@test-all.R#37) 
  5. Error: Check that user stats works (@test-all.R#41) 
  
  Error: testthat unit tests failed
  Execution halted