Running ‘testthat.R’ [308s/216s]
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/tests.html
  > # * https://testthat.r-lib.org/reference/test_package.html#special-files
  > 
  > library(testthat)
  > library(CodelistGenerator)
  > 
  > test_check("CodelistGenerator")
  Starting 2 test processes
  [ FAIL 3 | WARN 662 | SKIP 14 | PASS 395 ]
  
  ══ Skipped tests (14) ══════════════════════════════════════════════════════════
  • On CRAN (6): 'test-drugCodes.R:123:3', 'test-drugCodes.R:435:3',
    'test-getICD10StandardCodes.R:84:3', 'test-getCandidateCodes.R:310:3',
    'test-summariseCodeUse.R:2:1', 'test-summariseCodeUse.R:295:3'
  • Sys.getenv("CDM5_POSTGRESQL_DBNAME") == "" is TRUE (1): 'test-dbms.R:292:3'
  • Sys.getenv("CDM5_REDSHIFT_DBNAME") == "" is TRUE (4):
    'test-codesFrom.R:131:3', 'test-dbms.R:5:3', 'test-findUnmappedCodes.R:3:3',
    'test-summariseCodeUse.R:492:3'
  • Sys.getenv("CDM5_SQL_SERVER_SERVER") == "" is TRUE (1):
    'test-codesInUse.R:36:3'
  • Sys.getenv("SNOWFLAKE_SERVER") == "" is TRUE (1): 'test-dbms.R:154:3'
  • Sys.getenv("darwinDbDatabaseServer") == "" is TRUE (1):
    'test-synthea_sql_server.R:2:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-tableAchillesCodeUse.R:70:3'): table achilles code use expcted columns ──
  <rlib_error_package_not_found/rlang_error/error/condition>
  Error in `visOmopResults::fxTable(x, delim = .options$delim, style = .options$style, 
      na = .options$na, title = .options$title, subtitle = .options$subtitle, 
      caption = .options$caption, groupColumn = newGroupcolumn, 
      groupAsColumn = .options$groupAsColumn, groupOrder = .options$groupOrder, 
      colsToMergeRows = .options$colsToMergeRows)`: The package "flextable" is required.
  Backtrace:
      ▆
   1. └─CodelistGenerator::tableAchillesCodeUse(...) at test-tableAchillesCodeUse.R:70:3
   2.   └─CodelistGenerator:::internalTableAchillesResult(...)
   3.     └─visOmopResults::visOmopTable(...)
   4.       └─visOmopResults::fxTable(...)
   5.         └─rlang::check_installed("flextable")
  ── Error ('test-tableCodeUse.R:106:3'): table code use expcted columns ─────────
  <rlib_error_package_not_found/rlang_error/error/condition>
  Error in `visOmopResults::fxTable(x, delim = .options$delim, style = .options$style, 
      na = .options$na, title = .options$title, subtitle = .options$subtitle, 
      caption = .options$caption, groupColumn = newGroupcolumn, 
      groupAsColumn = .options$groupAsColumn, groupOrder = .options$groupOrder, 
      colsToMergeRows = .options$colsToMergeRows)`: The package "flextable" is required.
  Backtrace:
      ▆
   1. └─CodelistGenerator::tableCohortCodeUse(...) at test-tableCodeUse.R:106:3
   2.   └─CodelistGenerator:::internalTableCodeUse(...)
   3.     └─visOmopResults::visOmopTable(...)
   4.       └─visOmopResults::fxTable(...)
   5.         └─rlang::check_installed("flextable")
  ── Error ('test-tableCodeUse.R:262:3'): table code use output formats ──────────
  <rlib_error_package_not_found/rlang_error/error/condition>
  Error in `visOmopResults::fxTable(x, delim = .options$delim, style = .options$style, 
      na = .options$na, title = .options$title, subtitle = .options$subtitle, 
      caption = .options$caption, groupColumn = newGroupcolumn, 
      groupAsColumn = .options$groupAsColumn, groupOrder = .options$groupOrder, 
      colsToMergeRows = .options$colsToMergeRows)`: The package "flextable" is required.
  Backtrace:
      ▆
   1. └─CodelistGenerator::tableCodeUse(...) at test-tableCodeUse.R:262:3
   2.   └─CodelistGenerator:::internalTableCodeUse(...)
   3.     └─visOmopResults::visOmopTable(...)
   4.       └─visOmopResults::fxTable(...)
   5.         └─rlang::check_installed("flextable")
  
  [ FAIL 3 | WARN 662 | SKIP 14 | PASS 395 ]
  Error: Test failures
  Execution halted