Running ‘testthat.R’ [37s/63s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(huxtable)
  > 
  > 
  > we_are_in_R_CMD_check <- TRUE
  > test_check("huxtable")
  # weights:  9 (4 variable)
  initial  value 35.155593 
  iter  10 value 23.131901
  final  value 23.129234 
  converged
  [ FAIL 8 | WARN 2 | SKIP 24 | PASS 1210 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • 0-length tables don't work in flextable yet (1)
  • Awaiting ftExtra improvements (1)
  • Couldn't unload dplyr namespace (2)
  • Just too hard to do at the moment. (1)
  • Not testing, code doesn't play well with R CMD check (3)
  • On CRAN (15)
  • is.character(qp) is not TRUE (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-huxreg.R:104:3): huxreg number_format works correctly ───────────
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
      ▆
   1. ├─testthat::expect_match(...) at test-huxreg.R:104:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. ├─huxtable::to_screen(hr)
   5. └─huxtable:::to_screen.huxtable(hr)
   6.   └─huxtable:::character_matrix(...)
   7.     └─huxtable:::ncharw(dc$contents)
   8.       └─stringi::stri_width(x)
  ── Error (test-huxreg.R:133:3): huxreg statistics names shown in output ────────
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
      ▆
   1. ├─testthat::expect_match(...) at test-huxreg.R:133:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. ├─huxtable::to_screen(huxreg(m, statistics = c(foo = "nobs")))
   5. └─huxtable:::to_screen.huxtable(huxreg(m, statistics = c(foo = "nobs")))
   6.   └─huxtable:::character_matrix(...)
   7.     └─huxtable:::ncharw(dc$contents)
   8.       └─stringi::stri_width(x)
  ── Error (test-markdown.R:25:3): Output produced for basic types ───────────────
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
       ▆
    1. ├─testthat::expect_silent(to_screen(md_hux)) at test-markdown.R:25:2
    2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise)
    3. │   ├─testthat (local) .capture(...)
    4. │   │ ├─withr::with_output_sink(...)
    5. │   │ │ └─base::force(code)
    6. │   │ ├─base::withCallingHandlers(...)
    7. │   │ └─base::withVisible(code)
    8. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    9. ├─huxtable::to_screen(md_hux)
   10. └─huxtable:::to_screen.huxtable(md_hux)
   11.   └─huxtable:::character_matrix(...)
   12.     └─huxtable:::ncharw(dc$contents)
   13.       └─stringi::stri_width(x)
  ── Error (test-number-format-functions.R:7:3): fmt_percent ─────────────────────
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
      ▆
   1. ├─testthat::expect_match(to_screen(ht), "25.0%") at test-number-format-functions.R:7:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. ├─huxtable::to_screen(ht)
   5. └─huxtable:::to_screen.huxtable(ht)
   6.   └─huxtable:::character_matrix(...)
   7.     └─huxtable:::ncharw(dc$contents)
   8.       └─stringi::stri_width(x)
  ── Error (test-number-format-functions.R:22:3): fmt_pretty ─────────────────────
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
      ▆
   1. ├─testthat::expect_match(to_screen(ht), "100,000") at test-number-format-functions.R:22:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. ├─huxtable::to_screen(ht)
   5. └─huxtable:::to_screen.huxtable(ht)
   6.   └─huxtable:::character_matrix(...)
   7.     └─huxtable:::ncharw(dc$contents)
   8.       └─stringi::stri_width(x)
  ── Error (test-number-formatting.R:98:3): long_minus ───────────────────────────
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
      ▆
   1. ├─testthat::expect_match(to_screen(ht), "−3.1415") at test-number-formatting.R:98:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. ├─huxtable::to_screen(ht)
   5. └─huxtable:::to_screen.huxtable(ht)
   6.   └─huxtable:::character_matrix(...)
   7.     └─huxtable:::ncharw(dc$contents)
   8.       └─stringi::stri_width(x)
  ── Error (test-print.R:253:3): Bugfix: wide characters lead to infinite loop in to_screen ──
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
       ▆
    1. ├─testthat::expect_silent(to_screen(ht)) at test-print.R:253:2
    2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise)
    3. │   ├─testthat (local) .capture(...)
    4. │   │ ├─withr::with_output_sink(...)
    5. │   │ │ └─base::force(code)
    6. │   │ ├─base::withCallingHandlers(...)
    7. │   │ └─base::withVisible(code)
    8. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    9. ├─huxtable::to_screen(ht)
   10. └─huxtable:::to_screen.huxtable(ht)
   11.   └─huxtable:::character_matrix(...)
   12.     └─huxtable:::ncharw(dc$contents)
   13.       └─stringi::stri_width(x)
  ── Error (test-yy-end-to-end.R:216:3): huxtable.long_minus ─────────────────────
  Error in `stringi::stri_width(x)`: bytes encoding is not supported by this function
  Backtrace:
       ▆
    1. ├─testthat::expect_silent(to_screen(ht)) at test-yy-end-to-end.R:216:2
    2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise)
    3. │   ├─testthat (local) .capture(...)
    4. │   │ ├─withr::with_output_sink(...)
    5. │   │ │ └─base::force(code)
    6. │   │ ├─base::withCallingHandlers(...)
    7. │   │ └─base::withVisible(code)
    8. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    9. ├─huxtable::to_screen(ht)
   10. └─huxtable:::to_screen.huxtable(ht)
   11.   └─huxtable:::character_matrix(...)
   12.     └─huxtable:::ncharw(dc$contents)
   13.       └─stringi::stri_width(x)
  
  [ FAIL 8 | WARN 2 | SKIP 24 | PASS 1210 ]
  Error: Test failures
  Execution halted