Running 'testthat.R' [22s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(causalOT)
  > 
  > test_check("causalOT")
  [ FAIL 2 | WARN 0 | SKIP 53 | PASS 107 ]
  
  ══ Skipped tests (53) ══════════════════════════════════════════════════════════
  • On CRAN (24): 'test-OTmethod.R:28:3', 'test-OTmethod.R:97:3',
    'test-OTmethod.R:195:3', 'test-OTmethod.R:246:3', 'test-OTmethod.R:295:3',
    'test-OTmethod.R:392:3', 'test-OTmethod.R:477:3', 'test-OTmethod.R:519:3',
    'test-OTmethod.R:566:3', 'test-PSIS.R:2:3', 'test-PSIS.R:34:3',
    'test-PSIS.R:66:3', 'test-costMethod.R:50:3', 'test-cotClass.R:2:3',
    'test-cotClass.R:64:3', 'test-cotClass.R:118:3', 'test-cotClass.R:188:3',
    'test-cotClass.R:219:3', 'test-cotClass.R:323:3', 'test-cotClass.R:366:3',
    'test-cotOOP.R:2:3', 'test-cotOOP.R:110:3', 'test-cotOOP.R:237:3',
    'test-cotOOP.R:361:3'
  • Torch is not installed (29): 'test-OTmethod.R:2:3', 'test-OTmethod.R:60:3',
    'test-OTmethod.R:161:3', 'test-OTmethod.R:347:3', 'test-OTmethod.R:440:3',
    'test-barycentric_projection.R:2:3', 'test-barycentric_projection.R:91:3',
    'test-barycentric_projection.R:181:3', 'test-calc_weight.R:2:3',
    'test-costMethod.R:6:3', 'test-costMethod.R:106:3',
    'test-cotProblem.R:112:3', 'test-cotProblem.R:135:3', 'test-dual_opts.R:2:3',
    'test-dual_opts.R:150:3', 'test-dual_opts.R:285:3',
    'test-estimate_effect.R:2:3', 'test-estimate_effect.R:76:3',
    'test-estimate_effect.R:134:3', 'test-estimate_effect.R:192:3',
    'test-estimate_effect.R:354:3', 'test-estimate_effect.R:505:3',
    'test-estimate_effect.R:668:3', 'test-estimate_effect.R:712:3',
    'test-estimate_effect.R:757:3', 'test-estimate_effect.R:801:3',
    'test-gridSearch.R:2:3', 'test-gridSearch.R:106:3', 'test-gridSearch.R:155:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-balanceFunctions.R:62:3'): balanceFunction optimizes ───────────
  Error in `if (is.null(fit$convergence) || fit$convergence != 0) warning(fit$message)`: missing value where TRUE/FALSE needed
  Backtrace:
      ▆
   1. ├─testthat::expect_warning(w0_e <- ebw$solve(delta[1], NULL)) at test-balanceFunctions.R:62:3
   2. │ └─testthat:::quasi_capture(...)
   3. │   ├─testthat (local) .capture(...)
   4. │   │ └─base::withCallingHandlers(...)
   5. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   6. └─ebw$solve(delta[1], NULL)
   7.   └─causalOT:::lbfgs3c_R6_solve(...)
  ── Error ('test-gridSearch.R:82:3'): gridSearch EBW ────────────────────────────
  Error in `if (is.null(fit$convergence) || fit$convergence != 0) warning(fit$message)`: missing value where TRUE/FALSE needed
  Backtrace:
       ▆
    1. ├─testthat::capture_output(testthat::expect_warning(cw <- causalOT:::cot_solve(gs))) at test-gridSearch.R:82:3
    2. │ └─testthat::capture_output_lines(code, print, width = width)
    3. │   └─testthat:::eval_with_output(code, print = print, width = width)
    4. │     ├─withr::with_output_sink(path, withVisible(code))
    5. │     │ └─base::force(code)
    6. │     └─base::withVisible(code)
    7. ├─testthat::expect_warning(cw <- causalOT:::cot_solve(gs))
    8. │ └─testthat:::quasi_capture(...)
    9. │   ├─testthat (local) .capture(...)
   10. │   │ └─base::withCallingHandlers(...)
   11. │   └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo))
   12. ├─causalOT:::cot_solve(gs)
   13. └─causalOT:::cot_solve(gs)
   14.   └─object@solver$solve(penalty, w[k - 1])
   15.     └─causalOT:::lbfgs3c_R6_solve(...)
  
  [ FAIL 2 | WARN 0 | SKIP 53 | PASS 107 ]
  Error: Test failures
  Execution halted