Running ‘testthat.R’ [20s/12s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > # This file is part of the standard setup for testthat.
  > # It is recommended that you do not modify it.
  > #
  > # Where should you do additional test configuration?
  > # Learn more about the roles of various files in:
  > # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview
  > # * https://testthat.r-lib.org/articles/special-files.html
  > 
  > library(testthat)
  > library(visOmopResults)
  > 
  > test_check("visOmopResults")
  Starting 2 test processes
  [ FAIL 10 | WARN 14 | SKIP 3 | PASS 270 ]
  
  ══ Skipped tests (3) ═══════════════════════════════════════════════════════════
  • On CRAN (3): 'test-datatableInternal.R:11:3',
    'test-datatableInternal.R:26:3', 'test-formatTable.R:66:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-formatTable.R:25:3'): test it works ────────────────────────────
  <packageNotFoundError/error/condition>
  Error in `loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])`: there is no package called 'systemfonts'
  Backtrace:
       ▆
    1. ├─visOmopResults::formatTable(result, type = "flextable") at test-formatTable.R:25:3
    2. │ └─visOmopResults:::validateStyle(style, type)
    3. │   ├─base::eval(...)
    4. │   │ └─base::eval(...)
    5. │   └─visOmopResults:::flextableStyleInternal(styleName = style)
    6. └─base::loadNamespace(x)
    7.   ├─base::namespaceImportFrom(...)
    8.   │ └─base::asNamespace(ns)
    9.   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   10.     ├─base::namespaceImportFrom(...)
   11.     │ └─base::asNamespace(ns)
   12.     └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   13.       └─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   14.         └─base (local) withOneRestart(expr, restarts[[1L]])
   15.           └─base (local) doWithOneRestart(return(expr), restart)
  ── Error ('test-fxTable.R:9:3'): fxTableInternal ───────────────────────────────
  <rlib_error_package_not_found/rlang_error/error/condition>
  Error in `fxTableInternal(table_to_format, style = list(header = list(cell = officer::fp_cell(background.color = "#c8c8c8"), 
      text = officer::fp_text(bold = TRUE)), header_name = list(cell = officer::fp_cell(background.color = "#d9d9d9"), 
      text = officer::fp_text(bold = TRUE)), header_level = list(cell = officer::fp_cell(background.color = "#e1e1e1"), 
      text = officer::fp_text(bold = TRUE)), column_name = list(text = officer::fp_text(bold = TRUE)), 
      title = list(text = officer::fp_text(bold = TRUE, color = "blue"))), 
      na = NULL, title = "Test 1", subtitle = NULL, caption = NULL, 
      groupColumn = NULL, groupAsColumn = FALSE, groupOrder = NULL)`: The package "flextable" is required.
  Backtrace:
      ▆
   1. └─visOmopResults:::fxTableInternal(...) at test-fxTable.R:9:3
   2.   └─rlang::check_installed("flextable")
  ── Error ('test-fxTable.R:158:3'): fxTableInternal, test default styles and NULL ──
  <rlib_error_package_not_found/rlang_error/error/condition>
  Error in `fxTableInternal(table_to_format, style = NULL, na = NULL, title = "Test 1", 
      subtitle = NULL, caption = NULL, groupColumn = NULL, groupAsColumn = FALSE, 
      groupOrder = NULL)`: The package "flextable" is required.
  Backtrace:
      ▆
   1. └─visOmopResults:::fxTableInternal(...) at test-fxTable.R:158:3
   2.   └─rlang::check_installed("flextable")
  ── Error ('test-fxTable.R:231:3'): fxTableInternal, test merge ─────────────────
  <packageNotFoundError/error/condition>
  Error in `loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])`: there is no package called 'systemfonts'
  Backtrace:
       ▆
    1. ├─rlang::eval_bare(tableStyle(type = "flextable")) at test-fxTable.R:231:3
    2. └─base::loadNamespace(x)
    3.   ├─base::namespaceImportFrom(...)
    4.   │ └─base::asNamespace(ns)
    5.   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
    6.     ├─base::namespaceImportFrom(...)
    7.     │ └─base::asNamespace(ns)
    8.     └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
    9.       └─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   10.         └─base (local) withOneRestart(expr, restarts[[1L]])
   11.           └─base (local) doWithOneRestart(return(expr), restart)
  ── Error ('test-fxTable.R:284:3'): multiple groupColumn ────────────────────────
  <rlib_error_package_not_found/rlang_error/error/condition>
  Error in `fxTableInternal(table_to_format, delim = ":", style = list(subtitle = list(text = officer::fp_text(bold = TRUE, 
      font.size = 12, color = "blue")), body = list(text = officer::fp_text(color = "red"), 
      cell = officer::fp_cell(border = officer::fp_border())), 
      group_label = list(cell = officer::fp_cell(background.color = "#e1e1e1"), 
          text = officer::fp_text(color = "blue")), header_name = list(cell = officer::fp_cell(background.color = "black"), 
          text = officer::fp_text(color = "white"))), na = "-", 
      title = "Title test 2", subtitle = "Subtitle for test 2", 
      caption = "*This* is the caption", groupColumn = list(group_name_group_level = c("group_name", 
          "group_level")), groupAsColumn = TRUE)`: The package "flextable" is required.
  Backtrace:
      ▆
   1. └─visOmopResults:::fxTableInternal(...) at test-fxTable.R:284:3
   2.   └─rlang::check_installed("flextable")
  ── Error ('test-visTable.R:12:3'): visTable with SR ────────────────────────────
  <packageNotFoundError/error/condition>
  Error in `loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])`: there is no package called 'systemfonts'
  Backtrace:
       ▆
    1. ├─visOmopResults::visTable(...) at test-visTable.R:12:3
    2. │ └─visOmopResults::formatTable(...)
    3. │   └─visOmopResults:::validateStyle(style, type)
    4. │     ├─base::eval(...)
    5. │     │ └─base::eval(...)
    6. │     └─visOmopResults:::flextableStyleInternal(styleName = style)
    7. └─base::loadNamespace(x)
    8.   ├─base::namespaceImportFrom(...)
    9.   │ └─base::asNamespace(ns)
   10.   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   11.     ├─base::namespaceImportFrom(...)
   12.     │ └─base::asNamespace(ns)
   13.     └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   14.       └─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   15.         └─base (local) withOneRestart(expr, restarts[[1L]])
   16.           └─base (local) doWithOneRestart(return(expr), restart)
  ── Failure ('test-visOmopTable.R:42:3'): visOmopTable ──────────────────────────
  Expected `... <- NULL` to run without any errors.
  i Actually got a <packageNotFoundError> with text:
    there is no package called 'systemfonts'
  ── Error ('test-visOmopTable.R:52:3'): visOmopTable ────────────────────────────
  Error in `eval(code, test_env)`: object 'fx1' not found
  Backtrace:
      ▆
   1. └─testthat::expect_true("flextable" == class(fx1)) at test-visOmopTable.R:52:3
   2.   └─testthat::quasi_label(enquo(object), label, arg = "object")
   3.     └─rlang::eval_bare(expr, quo_get_env(quo))
  ── Error ('test-visOmopTable.R:191:3'): renameColumn works ─────────────────────
  <packageNotFoundError/error/condition>
  Error in `loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])`: there is no package called 'systemfonts'
  Backtrace:
       ▆
    1. ├─testthat::expect_warning(...) at test-visOmopTable.R:191:3
    2. │ └─testthat:::expect_condition_matching(...)
    3. │   └─testthat:::quasi_capture(...)
    4. │     ├─testthat (local) .capture(...)
    5. │     │ └─base::withCallingHandlers(...)
    6. │     └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
    7. ├─visOmopResults::visOmopTable(...)
    8. │ └─visOmopResults::visTable(...)
    9. │   └─visOmopResults::formatTable(...)
   10. │     └─visOmopResults:::validateStyle(style, type)
   11. │       ├─base::eval(...)
   12. │       │ └─base::eval(...)
   13. │       └─visOmopResults:::flextableStyleInternal(styleName = style)
   14. └─base::loadNamespace(x)
   15.   ├─base::namespaceImportFrom(...)
   16.   │ └─base::asNamespace(ns)
   17.   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   18.     ├─base::namespaceImportFrom(...)
   19.     │ └─base::asNamespace(ns)
   20.     └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   21.       └─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   22.         └─base (local) withOneRestart(expr, restarts[[1L]])
   23.           └─base (local) doWithOneRestart(return(expr), restart)
  ── Error ('test-visOmopTable.R:335:3'): empty table ────────────────────────────
  <packageNotFoundError/error/condition>
  Error in `loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])`: there is no package called 'systemfonts'
  Backtrace:
       ▆
    1. ├─visOmopResults::visOmopTable(...) at test-visOmopTable.R:335:3
    2. │ └─visOmopResults::visTable(...)
    3. │   └─visOmopResults::emptyTable(type = type)
    4. └─base::loadNamespace(x)
    5.   ├─base::namespaceImportFrom(...)
    6.   │ └─base::asNamespace(ns)
    7.   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
    8.     ├─base::namespaceImportFrom(...)
    9.     │ └─base::asNamespace(ns)
   10.     └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   11.       └─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   12.         └─base (local) withOneRestart(expr, restarts[[1L]])
   13.           └─base (local) doWithOneRestart(return(expr), restart)
  
  [ FAIL 10 | WARN 14 | SKIP 3 | PASS 270 ]
  Error: Test failures
  Execution halted