Running 'testthat.R'
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library("testthat")
  > library("RKorAPClient")
  > 
  > test_check("RKorAPClient")
  <KorAPConnection> 
  apiUrl:  https://korap.ids-mannheim.de/api/v1.0/ 
  Searching "contains(<base/s=s>, (Ameisenplage heimgesucht))" in "": 6 hits, took 2.739523037 s
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "Ameisenplage" in "": 136 hits, took 2.571208909 s
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "contains(<base/s=s>, (Ameisenplage heimgesucht))" in "": 6 hits [cached]
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "Ameisenplage" in "": 136 hits [cached]
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "heimgesucht" in "": 72431 hits, took 2.619841829 s
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "focus([tt/p=ADJA] {Newstickeritis})" in "corpusSigle=/W.D17/": 76 hits, took 0.28526211 s
  Retrieved page 1/2 in 0.287530311 s
  Retrieved page 2/2 in 0.287530311 s
  Joinging 52 kwics
  Aggregating 43 tokens
  Searching "focus([tt/p=ADJA] {Newstickeritis})" in "corpusSigle=/W.D17/": 76 hits, took 2.376259917 s
  Getting size of virtual corpus "corpusSigle=/W.D17/": 1604072771 tokens
  Searching "focus([tt/p=ADJA] {Newstickeritis})" in "corpusSigle=/W.D17/": 76 hits [cached]
  Getting size of virtual corpus "corpusSigle=/W.D17/": 1604072771 tokens
  Searching "reine" in "corpusSigle=/W.D17/": 43278 hits, took 2.241613065 s
  Getting size of virtual corpus "corpusSigle=/W.D17/": 1604072771 tokens
  Searching "XXXXXXXXAmeisenplage" in "": 0 hits, took 0.183558754 s
  Searching "Ameisenplage" in "pubDate since 2014": 44 hits, took 2.796853631 s
  Getting size of virtual corpus "pubDate since 2014": 7355886112 tokens
  Searching "contains(<base/s=s>, (Ameisenplage heimgesucht))" in "": 6 hits [cached]
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "Ameisenplage" in "": 136 hits [cached]
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "contains(<base/s=s>, (Ameisenplage heimgesucht))" in "": 6 hits [cached]
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "Ameisenplage" in "": 136 hits [cached]
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "heimgesucht" in "": 72431 hits [cached]
  Getting size of virtual corpus "": 21308764360 tokens
  Searching "Ameisenplage" in "pubDate since 2014": 44 hits, took 2.693763589 s
  Getting size of virtual corpus "pubDate since 2014": 7355886112 tokens
  Searching "Ameisenplage" in "pubDate since 2014": 44 hits [cached]
  Retrieved page 1/1 in 2.597914853 s
  Searching "Xmeisenplagx" in "pubDate in 2012": 0 hits, took 2.377644526 s
  Searching "Ameisenplage" in "pubDate since 2014": 44 hits, took 2.702153302 s
  Retrieved page 1/1 in 2.709863183 s
  Searching "[[xx" in ""
  <KorAPCorpusStats> 
  The whole corpus contains 21,308,764,360 tokens in 1,422,299,671 sentences in 75,299,087 documents.
  <KorAPCorpusStats> 
  The virtual corpus described by "pubDate in 2018" contains 837,477,694 tokens in 55,774,033 sentences in 2,815,683 documents.
  Searching "macht []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2013": 4306 hits, took 3.552772083 s
  Searching "macht []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2014": 4100 hits, took 3.385473251 s
  Searching "macht []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2015": 3989 hits, took 3.73587808 s
  Searching "macht []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2016": 4056 hits, took 3.490809918 s
  Searching "macht []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2017": 3987 hits, took 3.410538803 s
  Searching "macht []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2018": 4030 hits, took 3.40680018 s
  Searching "ergibt []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2013": 573 hits, took 3.312643638 s
  Searching "ergibt []{0,3} Sinn" in "textType = /Zeit.*/ & pubDate in 2014"[ FAIL 9 | WARN 0 | SKIP 0 | PASS 54 ]
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-demos.R:4:3): Alternatives over time highcharter example works ──
  Error: API did not return json
  Backtrace:
       ▆
    1. ├─... %>% hc_freq_by_year_ci(as.alternatives = TRUE) at test-demos.R:4:2
    2. ├─RKorAPClient::hc_freq_by_year_ci(., as.alternatives = TRUE)
    3. │ └─df %>% ...
    4. ├─RKorAPClient::frequencyQuery(...)
    5. ├─RKorAPClient::frequencyQuery(...)
    6. │ └─RKorAPClient .local(kco, ...)
    7. │   ├─... %>% ci(conf.level = conf.level)
    8. │   ├─... %>% mutate(total = sum(totalResults))
    9. │   ├─RKorAPClient::corpusQuery(...)
   10. │   └─RKorAPClient::corpusQuery(...)
   11. │     └─RKorAPClient .local(kco, ...)
   12. │       ├─... %>% bind_rows()
   13. │       └─purrr::pmap(...)
   14. │         └─RKorAPClient .f(query = .l[[1L]][[i]], vc = .l[[2L]][[i]], ...)
   15. │           ├─RKorAPClient::corpusQuery(...)
   16. │           └─RKorAPClient::corpusQuery(...)
   17. │             └─RKorAPClient .local(kco, ...)
   18. │               ├─RKorAPClient::apiCall(kco, paste0(requestUrl, "&count=0"))
   19. │               └─RKorAPClient::apiCall(kco, paste0(requestUrl, "&count=0"))
   20. │                 └─RKorAPClient .local(kco, ...)
   21. ├─RKorAPClient::ci(., conf.level = conf.level)
   22. │ └─df %>% dplyr::filter(total <= 0) %>% ...
   23. ├─dplyr::mutate(., f = NA, conf.low = NA, conf.high = NA)
   24. ├─dplyr::filter(., total <= 0)
   25. ├─dplyr::mutate(., total = sum(totalResults))
   26. ├─dplyr::group_by(., vc)
   27. └─dplyr::bind_rows(.)
   28.   └─rlang::list2(...)
  ── Error (test-demos.R:18:3): Multiple queries over time highcharter example works ──
  Error in `h(simpleError(msg, call))`: error in evaluating the argument 'kco' in selecting a method for function 'frequencyQuery': lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. ├─... %>% hc_freq_by_year_ci(as.alternatives = FALSE) at test-demos.R:18:2
    2. ├─RKorAPClient::hc_freq_by_year_ci(., as.alternatives = FALSE)
    3. │ └─df %>% ...
    4. ├─RKorAPClient::frequencyQuery(...)
    5. ├─methods::new("KorAPConnection", verbose = TRUE)
    6. │ ├─methods::initialize(value, ...)
    7. │ └─RKorAPClient::initialize(value, ...)
    8. │   └─RKorAPClient .local(.Object, ...)
    9. │     ├─RKorAPClient::apiCall(...)
   10. │     └─RKorAPClient::apiCall(...)
   11. │       └─RKorAPClient .local(kco, ...)
   12. │         └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
   13. │           └─jsonlite:::parse_and_simplify(...)
   14. │             └─jsonlite:::parseJSON(txt, bigint_as_char)
   15. │               └─jsonlite:::parse_string(txt, bigint_as_char)
   16. └─base::.handleSimpleError(...)
   17.   └─base h(simpleError(msg, call))
  ── Error (test-demos.R:32:3): Single query in multiple over time highcharter example works ──
  Error in `h(simpleError(msg, call))`: error in evaluating the argument 'kco' in selecting a method for function 'frequencyQuery': lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. ├─... %>% hc_freq_by_year_ci(as.alternatives = FALSE) at test-demos.R:32:2
    2. ├─RKorAPClient::hc_freq_by_year_ci(., as.alternatives = FALSE)
    3. │ └─df %>% ...
    4. ├─RKorAPClient::frequencyQuery(...)
    5. ├─methods::new("KorAPConnection", verbose = TRUE)
    6. │ ├─methods::initialize(value, ...)
    7. │ └─RKorAPClient::initialize(value, ...)
    8. │   └─RKorAPClient .local(.Object, ...)
    9. │     ├─RKorAPClient::apiCall(...)
   10. │     └─RKorAPClient::apiCall(...)
   11. │       └─RKorAPClient .local(kco, ...)
   12. │         └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
   13. │           └─jsonlite:::parse_and_simplify(...)
   14. │             └─jsonlite:::parseJSON(txt, bigint_as_char)
   15. │               └─jsonlite:::parse_string(txt, bigint_as_char)
   16. └─base::.handleSimpleError(...)
   17.   └─base h(simpleError(msg, call))
  ── Error (test-demos.R:46:3): Single query over time highcharter example works ──
  Error in `h(simpleError(msg, call))`: error in evaluating the argument 'kco' in selecting a method for function 'frequencyQuery': lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. ├─... %>% hc_freq_by_year_ci(as.alternatives = FALSE) at test-demos.R:46:2
    2. ├─RKorAPClient::hc_freq_by_year_ci(., as.alternatives = FALSE)
    3. │ └─df %>% ...
    4. ├─RKorAPClient::frequencyQuery(...)
    5. ├─methods::new("KorAPConnection", verbose = TRUE)
    6. │ ├─methods::initialize(value, ...)
    7. │ └─RKorAPClient::initialize(value, ...)
    8. │   └─RKorAPClient .local(.Object, ...)
    9. │     ├─RKorAPClient::apiCall(...)
   10. │     └─RKorAPClient::apiCall(...)
   11. │       └─RKorAPClient .local(kco, ...)
   12. │         └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
   13. │           └─jsonlite:::parse_and_simplify(...)
   14. │             └─jsonlite:::parseJSON(txt, bigint_as_char)
   15. │               └─jsonlite:::parse_string(txt, bigint_as_char)
   16. └─base::.handleSimpleError(...)
   17.   └─base h(simpleError(msg, call))
  ── Error (test-demos.R:57:3): Auto conditions over time highcharter example works ──
  Error: lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. └─methods::new("KorAPConnection", verbose = TRUE) at test-demos.R:57:2
    2.   ├─methods::initialize(value, ...)
    3.   └─RKorAPClient::initialize(value, ...)
    4.     └─RKorAPClient .local(.Object, ...)
    5.       ├─RKorAPClient::apiCall(...)
    6.       └─RKorAPClient::apiCall(...)
    7.         └─RKorAPClient .local(kco, ...)
    8.           └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
    9.             └─jsonlite:::parse_and_simplify(...)
   10.               └─jsonlite:::parseJSON(txt, bigint_as_char)
   11.                 └─jsonlite:::parse_string(txt, bigint_as_char)
  ── Error (test-demos.R:73:3): Single condition over time highcharter example works ──
  Error: lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. └─methods::new("KorAPConnection", verbose = TRUE) at test-demos.R:73:2
    2.   ├─methods::initialize(value, ...)
    3.   └─RKorAPClient::initialize(value, ...)
    4.     └─RKorAPClient .local(.Object, ...)
    5.       ├─RKorAPClient::apiCall(...)
    6.       └─RKorAPClient::apiCall(...)
    7.         └─RKorAPClient .local(kco, ...)
    8.           └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
    9.             └─jsonlite:::parse_and_simplify(...)
   10.               └─jsonlite:::parseJSON(txt, bigint_as_char)
   11.                 └─jsonlite:::parse_string(txt, bigint_as_char)
  ── Error (test-demos.R:88:3): Multiple conditions over time highcharter example works ──
  Error: lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. └─methods::new("KorAPConnection", verbose = TRUE) at test-demos.R:88:2
    2.   ├─methods::initialize(value, ...)
    3.   └─RKorAPClient::initialize(value, ...)
    4.     └─RKorAPClient .local(.Object, ...)
    5.       ├─RKorAPClient::apiCall(...)
    6.       └─RKorAPClient::apiCall(...)
    7.         └─RKorAPClient .local(kco, ...)
    8.           └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
    9.             └─jsonlite:::parse_and_simplify(...)
   10.               └─jsonlite:::parseJSON(txt, bigint_as_char)
   11.                 └─jsonlite:::parse_string(txt, bigint_as_char)
  ── Error (test-demos.R:104:3): Multiple conditions and queries over time highcharter example works ──
  Error: lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. └─methods::new("KorAPConnection", verbose = TRUE) at test-demos.R:104:2
    2.   ├─methods::initialize(value, ...)
    3.   └─RKorAPClient::initialize(value, ...)
    4.     └─RKorAPClient .local(.Object, ...)
    5.       ├─RKorAPClient::apiCall(...)
    6.       └─RKorAPClient::apiCall(...)
    7.         └─RKorAPClient .local(kco, ...)
    8.           └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
    9.             └─jsonlite:::parse_and_simplify(...)
   10.               └─jsonlite:::parseJSON(txt, bigint_as_char)
   11.                 └─jsonlite:::parse_string(txt, bigint_as_char)
  ── Error (test-demos.R:121:3): collocationScoreQuery works iwth hchart and hc_add_onclick_korap_search ──
  Error: lexical error: invalid char in json text.
                                         Proxy error: Connection refused
                       (right here) ------^
  
  Backtrace:
       ▆
    1. └─methods::new("KorAPConnection", cache = TRUE, verbose = TRUE) at test-demos.R:121:2
    2.   ├─methods::initialize(value, ...)
    3.   └─RKorAPClient::initialize(value, ...)
    4.     └─RKorAPClient .local(.Object, ...)
    5.       ├─RKorAPClient::apiCall(...)
    6.       └─RKorAPClient::apiCall(...)
    7.         └─RKorAPClient .local(kco, ...)
    8.           └─jsonlite::fromJSON(content(resp, "text", encoding = "UTF-8"))
    9.             └─jsonlite:::parse_and_simplify(...)
   10.               └─jsonlite:::parseJSON(txt, bigint_as_char)
   11.                 └─jsonlite:::parse_string(txt, bigint_as_char)
  
  [ FAIL 9 | WARN 0 | SKIP 0 | PASS 54 ]
  Error: Test failures
  Execution halted