Running ‘testthat.R’ [5s/7s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(cellpypes)
  > 
  > test_check("cellpypes")
  [ FAIL 4 | WARN 5 | SKIP 0 | PASS 44 ]
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-find_knn.R:4:3'): docu example works ───────────────────────────
  Error in `find_knn(fmat, k = 15)`: requireNamespace("RcppAnnoy", quietly = TRUE) is not TRUE
  Backtrace:
      ▆
   1. └─cellpypes::find_knn(fmat, k = 15) at test-find_knn.R:4:3
   2.   └─base::stopifnot(requireNamespace("RcppAnnoy", quietly = TRUE))
  ── Error ('test-neighbor_pooling.R:3:1'): (code run outside of `test_that()`) ──
  Error in `find_knn(dummy_dat, k = 15)`: requireNamespace("RcppAnnoy", quietly = TRUE) is not TRUE
  Backtrace:
      ▆
   1. └─cellpypes::find_knn(dummy_dat, k = 15) at test-neighbor_pooling.R:3:1
   2.   └─base::stopifnot(requireNamespace("RcppAnnoy", quietly = TRUE))
  ── Failure ('test-pseudobulk.R:10:3'): class_to_deseq2 example working ─────────
  `{ ... }` threw an unexpected error.
  Message: Install DESeq2 to use class_to_deseq2 function.
  Class:   simpleError/error/condition
  Backtrace:
      ▆
   1. ├─testthat::expect_error(...) at test-pseudobulk.R:10: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. └─cellpypes::class_to_deseq2(obj, meta_data, "T", ~treatment) at test-pseudobulk.R:20:7
  ── Error ('test-pseudobulk.R:61:3'): class_to_deseq2 stops gracefully if class has zero cells. ──
  Error in `class_to_deseq2(dds, meta_data, "T", ~treatment)`: Install DESeq2 to use class_to_deseq2 function.
  Backtrace:
      ▆
   1. ├─testthat::expect_error(...) at test-pseudobulk.R:61: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. └─cellpypes::class_to_deseq2(dds, meta_data, "T", ~treatment)
  
  [ FAIL 4 | WARN 5 | SKIP 0 | PASS 44 ]
  Error: Test failures
  Execution halted