Running ‘testthat.R’ [394s/287s]
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(xplainfi)
  > 
  > test_check("xplainfi")
  Starting 2 test processes.
  Saving _problems/test-WVIM-274.R
  Saving _problems/test-WVIM-340.R
  Saving _problems/test-WVIM-359.R
  [ FAIL 3 | WARN 3 | SKIP 7 | PASS 1785 ]
  
  ══ Skipped tests (7) ═══════════════════════════════════════════════════════════
  • On CRAN (6): 'test-ConditionalSAGE.R:51:2', 'test-ConditionalSAGE.R:139:2',
    'test-ConditionalSAGE.R:157:2', 'test-ConditionalSAGE.R:199:2',
    'test-ConditionalSAGE.R:261:2', 'test-MarginalSAGE.R:230:2'
  • as.numeric(R.version$minor) >= 6 is TRUE (1): 'test-bibentries.R:3:2'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-WVIM.R:274:2'): LOCO ci_method='lei' alternative='greater' produces one-sided CIs ──
  Error in `if (p < 0.99999) 1 - p else F(z, lower.tail = FALSE)`: missing value where TRUE/FALSE needed
  Backtrace:
      ▆
   1. └─loco$importance(ci_method = "lei", alternative = "two.sided") at test-WVIM.R:274:9
   2.   └─xplainfi:::importance_loco(...)
   3.     └─xplainfi:::test_obs_importance(...)
   4.       └─base::lapply(...)
   5.         └─xplainfi (local) FUN(X[[i]], ...)
   6.           ├─stats (local) test_function(...)
   7.           └─stats:::wilcox.test.default(...)
   8.             └─stats:::.wilcox_test_one_pval_asymp(STAT, n, alternative, correct)
  ── Error ('test-WVIM.R:340:2'): LOCO ci_method='lei' works without warnings for cross-validation ──
  Error in `if (p < 0.99999) 1 - p else F(z, lower.tail = FALSE)`: missing value where TRUE/FALSE needed
  Backtrace:
       ▆
    1. ├─base::suppressWarnings(loco$importance(ci_method = "lei")) at test-WVIM.R:340:9
    2. │ └─base::withCallingHandlers(...)
    3. └─loco$importance(ci_method = "lei")
    4.   └─xplainfi:::importance_loco(...)
    5.     └─xplainfi:::test_obs_importance(...)
    6.       └─base::lapply(...)
    7.         └─xplainfi (local) FUN(X[[i]], ...)
    8.           ├─stats (local) test_function(...)
    9.           └─stats:::wilcox.test.default(...)
   10.             └─stats:::.wilcox_test_one_pval_asymp(STAT, n, alternative, correct)
  ── Error ('test-WVIM.R:359:2'): WVIM ci_method='lei' works for leave-out direction ──
  Error in `if (p < 0.99999) 1 - p else F(z, lower.tail = FALSE)`: missing value where TRUE/FALSE needed
  Backtrace:
      ▆
   1. └─wvim$importance(ci_method = "lei") at test-WVIM.R:359:9
   2.   └─xplainfi:::importance_loco(...)
   3.     └─xplainfi:::test_obs_importance(...)
   4.       └─base::lapply(...)
   5.         └─xplainfi (local) FUN(X[[i]], ...)
   6.           ├─stats (local) test_function(...)
   7.           └─stats:::wilcox.test.default(...)
   8.             └─stats:::.wilcox_test_one_pval_asymp(STAT, n, alternative, correct)
  
  [ FAIL 3 | WARN 3 | SKIP 7 | PASS 1785 ]
  Error:
  ! Test failures.
  Execution halted