Running ‘testthat.R’ [14s/19s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(shinyvalidate)
  > 
  > test_check("shinyvalidate")
    75: <Anonymous>
    73: rule$rule
    59: <Anonymous>
    58: mapply
    57: validator_info$validator$`_validate_impl`
    56: self$`_validate_impl`
    55: iv$validate
    35: eval [test-validator.R#115]
    34: eval
    25: test_code
    24: test_that
    23: eval [test-validator.R#113]
    22: eval
    13: test_code
    12: source_file
    11: FUN
    10: lapply
     4: test_files_serial
     3: test_files
     2: test_dir
     1: test_check
    75: <Anonymous>
    73: rule$rule
    59: <Anonymous>
    58: mapply
    57: self$`_validate_impl`
    56: self$validate
    55: child_iv$is_valid
    35: eval [test-validator.R#115]
    34: eval
    25: test_code
    24: test_that
    23: eval [test-validator.R#113]
    22: eval
    13: test_code
    12: source_file
    11: FUN
    10: lapply
     4: test_files_serial
     3: test_files
     2: test_dir
     1: test_check
    76: <Anonymous>
    74: rule$rule
    60: <Anonymous>
    59: mapply
    58: validator_info$validator$`_validate_impl`
    57: self$`_validate_impl`
    56: self$validate
    55: iv$is_valid
    35: eval [test-validator.R#115]
    34: eval
    25: test_code
    24: test_that
    23: eval [test-validator.R#113]
    22: eval
    13: test_code
    12: source_file
    11: FUN
    10: lapply
     4: test_files_serial
     3: test_files
     2: test_dir
     1: test_check
    75: <Anonymous>
    73: rule$rule
    59: <Anonymous>
    58: mapply
    57: self$`_validate_impl`
    56: self$validate
    55: child_iv$is_valid
    35: eval [test-validator.R#115]
    34: eval
    25: test_code
    24: test_that
    23: eval [test-validator.R#113]
    22: eval
    13: test_code
    12: source_file
    11: FUN
    10: lapply
     4: test_files_serial
     3: test_files
     2: test_dir
     1: test_check
    80: stop
    79: <Anonymous>
    77: rule$rule
    63: <Anonymous>
    62: mapply
    61: self$`_validate_impl`
    60: iv$validate
    35: eval [test-validator.R#201]
    34: eval
    25: test_code
    24: test_that
    23: eval [test-validator.R#199]
    22: eval
    13: test_code
    12: source_file
    11: FUN
    10: lapply
     4: test_files_serial
     3: test_files
     2: test_dir
     1: test_check
    81: <Anonymous>
    80: stop
    79: <Anonymous>
    77: rule$rule
    63: <Anonymous>
    62: mapply
    61: self$`_validate_impl`
    60: iv$validate
    35: eval [test-validator.R#201]
    34: eval
    25: test_code
    24: test_that
    23: eval [test-validator.R#199]
    22: eval
    13: test_code
    12: source_file
    11: FUN
    10: lapply
     4: test_files_serial
     3: test_files
     2: test_dir
     1: test_check
  [ FAIL 6 | WARN 4 | SKIP 1 | PASS 1462 ]
  
  ══ Skipped tests (1) ═══════════════════════════════════════════════════════════
  • On CRAN (1): 'test-validator.R:201:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Failure ('test-rules.R:6:3'): `sv_optional()` basic use cases ───────────────
  iv$is_valid() is not TRUE
  
  `actual`:   FALSE
  `expected`: TRUE 
  Backtrace:
       ▆
    1. ├─shiny::withReactiveDomain(...) at test-rules.R:6:2
    2. │ └─promises::with_promise_domain(...)
    3. │   └─domain$wrapSync(expr)
    4. │     └─base::force(expr)
    5. ├─shiny::isolate(...) at test-rules.R:10:4
    6. │ ├─shiny::..stacktraceoff..(...)
    7. │ └─ctx$run(...)
    8. │   ├─promises::with_promise_domain(...)
    9. │   │ └─domain$wrapSync(expr)
   10. │   ├─shiny::withReactiveDomain(...)
   11. │   │ └─promises::with_promise_domain(...)
   12. │   │   └─domain$wrapSync(expr)
   13. │   │     └─base::force(expr)
   14. │   └─env$runWith(self, func)
   15. │     └─shiny (local) contextFunc()
   16. │       └─shiny::..stacktraceon..(expr)
   17. └─testthat::expect_true(iv$is_valid()) at test-rules.R:11:6
  ── Failure ('test-rules.R:6:3'): `sv_optional()` basic use cases ───────────────
  iv$validate() (`actual`) not identical to rlang::list2(`:=`("mock-session-x", NULL)) (`expected`).
  
  `actual$mock-session-x` is a list
  `expected$mock-session-x` is NULL
  Backtrace:
       ▆
    1. ├─shiny::withReactiveDomain(...) at test-rules.R:6:2
    2. │ └─promises::with_promise_domain(...)
    3. │   └─domain$wrapSync(expr)
    4. │     └─base::force(expr)
    5. ├─shiny::isolate(...) at test-rules.R:10:4
    6. │ ├─shiny::..stacktraceoff..(...)
    7. │ └─ctx$run(...)
    8. │   ├─promises::with_promise_domain(...)
    9. │   │ └─domain$wrapSync(expr)
   10. │   ├─shiny::withReactiveDomain(...)
   11. │   │ └─promises::with_promise_domain(...)
   12. │   │   └─domain$wrapSync(expr)
   13. │   │     └─base::force(expr)
   14. │   └─env$runWith(self, func)
   15. │     └─shiny (local) contextFunc()
   16. │       └─shiny::..stacktraceon..(expr)
   17. └─testthat::expect_identical(...) at test-rules.R:12:6
  ── Failure ('test-rules.R:643:3'): the `sv_required()` rule function works properly ──
  rule(NULL) has type 'NULL', not 'character'.
  Backtrace:
      ▆
   1. └─shinyvalidate (local) expect_sv_fail(rule, !!!always_fail) at test-rules.R:643:2
   2.   └─base::lapply(...) at test-rules.R:64:2
   3.     └─shinyvalidate (local) FUN(X[[i]], ...)
   4.       └─testthat::expect_type(rule(!!x), "character") at test-rules.R:67:6
  ── Failure ('test-validator.R:27:3'): InputValidator add_rule() ────────────────
  iv$validate() (`actual`) not identical to rlang::list2(...) (`expected`).
  
      names(actual)         | names(expected)          
  [1] "mock-session-inputB" - "mock-session-inputA" [1]
  [2] "mock-session-inputC" - "mock-session-inputB" [2]
  [3] "mock-session-inputA" - "mock-session-inputC" [3]
  
  `actual$mock-session-inputA` is NULL
  `expected$mock-session-inputA` is a list
  Backtrace:
       ▆
    1. ├─shiny::withReactiveDomain(...) at test-validator.R:27:2
    2. │ └─promises::with_promise_domain(...)
    3. │   └─domain$wrapSync(expr)
    4. │     └─base::force(expr)
    5. ├─shiny::isolate(...) at test-validator.R:40:4
    6. │ ├─shiny::..stacktraceoff..(...)
    7. │ └─ctx$run(...)
    8. │   ├─promises::with_promise_domain(...)
    9. │   │ └─domain$wrapSync(expr)
   10. │   ├─shiny::withReactiveDomain(...)
   11. │   │ └─promises::with_promise_domain(...)
   12. │   │   └─domain$wrapSync(expr)
   13. │   │     └─base::force(expr)
   14. │   └─env$runWith(self, func)
   15. │     └─shiny (local) contextFunc()
   16. │       └─shiny::..stacktraceon..(expr)
   17. └─testthat::expect_identical(...) at test-validator.R:43:6
  ── Failure ('test-validator.R:27:3'): InputValidator add_rule() ────────────────
  iv$validate() (`actual`) not identical to rlang::list2(...) (`expected`).
  
      names(actual)         | names(expected)          
  [1] "mock-session-inputC" - "mock-session-inputA" [1]
  [2] "mock-session-inputA" - "mock-session-inputC" [2]
  [3] "mock-session-inputB" | "mock-session-inputB" [3]
  
  `actual$mock-session-inputA` is NULL
  `expected$mock-session-inputA` is a list
  Backtrace:
       ▆
    1. ├─shiny::withReactiveDomain(...) at test-validator.R:27:2
    2. │ └─promises::with_promise_domain(...)
    3. │   └─domain$wrapSync(expr)
    4. │     └─base::force(expr)
    5. ├─shiny::isolate(...) at test-validator.R:53:4
    6. │ ├─shiny::..stacktraceoff..(...)
    7. │ └─ctx$run(...)
    8. │   ├─promises::with_promise_domain(...)
    9. │   │ └─domain$wrapSync(expr)
   10. │   ├─shiny::withReactiveDomain(...)
   11. │   │ └─promises::with_promise_domain(...)
   12. │   │   └─domain$wrapSync(expr)
   13. │   │     └─base::force(expr)
   14. │   └─env$runWith(self, func)
   15. │     └─shiny (local) contextFunc()
   16. │       └─shiny::..stacktraceon..(expr)
   17. └─testthat::expect_identical(...) at test-validator.R:55:6
  ── Failure ('test-validator.R:115:3'): InputValidator$fields recurses over child validators ──
  iv$is_valid() is not FALSE
  
  `actual`:   TRUE 
  `expected`: FALSE
  Backtrace:
       ▆
    1. ├─shiny::withReactiveDomain(...) at test-validator.R:115:2
    2. │ └─promises::with_promise_domain(...)
    3. │   └─domain$wrapSync(expr)
    4. │     └─base::force(expr)
    5. ├─shiny::isolate(...) at test-validator.R:128:4
    6. │ ├─shiny::..stacktraceoff..(...)
    7. │ └─ctx$run(...)
    8. │   ├─promises::with_promise_domain(...)
    9. │   │ └─domain$wrapSync(expr)
   10. │   ├─shiny::withReactiveDomain(...)
   11. │   │ └─promises::with_promise_domain(...)
   12. │   │   └─domain$wrapSync(expr)
   13. │   │     └─base::force(expr)
   14. │   └─env$runWith(self, func)
   15. │     └─shiny (local) contextFunc()
   16. │       └─shiny::..stacktraceon..(expr)
   17. └─testthat::expect_false(iv$is_valid()) at test-validator.R:139:6
  
  [ FAIL 6 | WARN 4 | SKIP 1 | PASS 1462 ]
  Error: Test failures
  Execution halted