Running ‘spelling.R’ [0s/0s]
  Running ‘testthat.R’ [450s/270s]
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(CohortCharacteristics)
  > 
  > test_check("CohortCharacteristics")
  Starting 2 test processes
  [ FAIL 2 | WARN 4 | SKIP 17 | PASS 208 ]
  
  ══ Skipped tests (17) ══════════════════════════════════════════════════════════
  • On CRAN (17): 'test-benchmarkCohortCharacteristics.R:2:3',
    'test-plotCharacteristics.R:2:3', 'test-plotCharacteristics.R:136:3',
    'test-plotCohortOverlap.R:2:3', 'test-plotCohortTiming.R:2:3',
    'test-plotCohortTiming.R:94:3', 'test-plotLargeScaleCharacteristics.R:3:3',
    'test-summariseCohortCount.R:2:3',
    'test-summariseLargeScaleCharacteristics.R:2:3',
    'test-tableCharacteristics.R:2:3', 'test-tableCharacteristics.R:120:3',
    'test-tableCohortOverlap.R:2:3', 'test-tableCohortTiming.R:2:3',
    'test-tableLargeScaleCharacteristics.R:2:3',
    'test-summariseCharacteristics.R:1159:3',
    'test-summariseCharacteristics.R:1389:3',
    'test-summariseCharacteristics.R:1505:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Failure ('test-summariseCharacteristics.R:337:3'): test summariseCharacteristics ──
  Expected `... <- NULL` to run without any errors.
  i Actually got a <rlang_error> with text:
    Failed to collect lazy table.
    Caused by error in `dbSendQuery()`:
    ! rapi_prepare: Failed to prepare query SELECT
      strata_id,
      SUM(variable_00047 * ".data".id_hsb) AS counts_variable_00047,
      SUM(variable_00048 * ".data".id_hsb) AS counts_variable_00048,
      SUM(variable_00049 * ".data".id_hsb) AS counts_variable_00049
    FROM (
      SELECT q01.*, 1.0 AS id_hsb
      FROM (
        SELECT strata_id, subject_id, variable_00047, variable_00048, variable_00049
        FROM og_066_1740841689
        LEFT JOIN test_dus_cohort_set
          ON (og_066_1740841689.cohort_definition_id = test_dus_cohort_set.cohort_definition_id)
        INNER JOIN og_076_1740841694
          ON (test_dus_cohort_set.cohort_name = og_076_1740841694.cohort_name)
      ) q01
    ) q01
    GROUP BY strata_id
    Error: Binder Error: Referenced table ".data" not found!
    Candidate tables: "q01"
    
    LINE 3:   SUM(variable_00047 * ".data".id_hsb) AS counts_variable_00047,
                                   ^
  ── Failure ('test-summariseCharacteristics.R:346:3'): test summariseCharacteristics ──
  any(...) is not FALSE
  
  `actual`:   TRUE 
  `expected`: FALSE
  
  [ FAIL 2 | WARN 4 | SKIP 17 | PASS 208 ]
  Error: Test failures
  Execution halted