Running ‘testthat.R’ [14s/16s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(slider)
  > 
  > if (requireNamespace("xml2")) {
  +   test_check("slider", reporter = MultiReporter$new(reporters = list(JunitReporter$new(file = "test-results.xml"), CheckReporter$new())))
  + } else {
  +   test_check("slider")
  + }
  Loading required namespace: xml2
  ── 1. Error: inner type is allowed to be different (@test-hop-index-vec.R#12)  ─
  Can't convert <double> to <list>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 2. Failure: inner type can be restricted with list_of (@test-hop-index-vec.R#
  `hop_index_vec(...)` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <double> to <list_of<double>>.
  Backtrace:
    1. testthat::expect_error(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 3. Error: .ptype is respected (@test-hop-index-vec.R#31)  ───────────────────
  Can't convert <double> to <date>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 4. Failure: names are not placed on data frames rownames (@test-hop-index-vec
  rownames(out) not equal to c("1", "2").
  2/2 mismatches
  x[1]: "a"
  y[1]: "1"
  
  x[2]: "b"
  y[2]: "2"
  
  ── 5. Error: inner type is allowed to be different (@test-hop-vec.R#12)  ───────
  Can't convert <double> to <list>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 6. Failure: inner type can be restricted with list_of (@test-hop-vec.R#19)  ─
  `hop_vec(...)` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <double> to <list_of<double>>.
  Backtrace:
    1. testthat::expect_error(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 7. Error: .ptype is respected (@test-hop-vec.R#31)  ─────────────────────────
  Can't convert <double> to <date>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 8. Failure: names are not placed on data frames rownames (@test-hop-vec.R#97)
  rownames(out) not equal to c("1", "2").
  2/2 mismatches
  x[1]: "a"
  y[1]: "1"
  
  x[2]: "b"
  y[2]: "2"
  
  ── 9. Error: pslide_index_chr() can coerce (@test-pslide-index-vec.R#54)  ──────
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equivalent(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 10. Error: inner type is allowed to be different (@test-pslide-period-vec.R#1
  Can't convert <double> to <list>.
  Backtrace:
    1. testthat::expect_equal(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 11. Failure: inner type can be restricted with list_of (@test-pslide-period-v
  `pslide_period_vec(...)` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <double> to <list_of<double>>.
  Backtrace:
    1. testthat::expect_error(...)
   10. vctrs::vec_default_cast(...)
   11. vctrs::stop_incompatible_cast(...)
   12. vctrs::stop_incompatible_type(...)
   13. vctrs:::stop_incompatible(...)
   14. vctrs:::stop_vctrs(...)
  
  ── 12. Error: .ptype is respected (@test-pslide-period-vec.R#31)  ──────────────
  Can't convert <double> to <date>.
  Backtrace:
    1. testthat::expect_equal(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 13. Error: pslide_period_chr() can coerce (@test-pslide-period-vec.R#117)  ──
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equal(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 14. Error: pslide_chr() can coerce (@test-pslide-vec.R#48)  ─────────────────
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equivalent(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 15. Error: inner type is allowed to be different (@test-slide-index-vec.R#12)
  Can't convert <double> to <list>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 16. Failure: inner type can be restricted with list_of (@test-slide-index-vec
  `slide_index_vec(...)` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <double> to <list_of<double>>.
  Backtrace:
    1. testthat::expect_error(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 17. Error: .ptype is respected (@test-slide-index-vec.R#31)  ────────────────
  Can't convert <double> to <date>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 18. Error: slide_index_chr() can coerce (@test-slide-index-vec.R#99)  ───────
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equal(slide_index_chr(1, 1, ~.x), "1")
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 19. Failure: cannot use an invalid .complete value (@test-slide-index.R#923) 
  `slide_index(1, 1, identity, .complete = "hi")` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert `.complete` <character> to <logical>.
  Backtrace:
    1. testthat::expect_error(...)
   11. vctrs::vec_default_cast(...)
   12. vctrs::stop_incompatible_cast(...)
   13. vctrs::stop_incompatible_type(...)
   14. vctrs:::stop_incompatible(...)
   15. vctrs:::stop_vctrs(...)
  
  ── 20. Failure: row names are not extracted from data frames (@test-slide-index.
  names(slide_index(x, i, ~.x)) not equal to NULL.
  Types not compatible: character is not NULL
  
  ── 21. Failure: names are retained on inner sliced object (@test-slide-index.R#1
  slide_index(x, i, ~rownames(.x)) not equal to as.list(rownames(x)).
  names for target but not for current
  
  ── 22. Error: slide_index2_chr() can coerce (@test-slide-index2-vec.R#49)  ─────
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equal(slide_index2_chr(1, 1, 1, ~.x), "1")
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 23. Error: inner type is allowed to be different (@test-slide-period-vec.R#12
  Can't convert <double> to <list>.
  Backtrace:
    1. testthat::expect_equal(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 24. Failure: inner type can be restricted with list_of (@test-slide-period-ve
  `slide_period_vec(...)` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <double> to <list_of<double>>.
  Backtrace:
    1. testthat::expect_error(...)
   10. vctrs::vec_default_cast(...)
   11. vctrs::stop_incompatible_cast(...)
   12. vctrs::stop_incompatible_type(...)
   13. vctrs:::stop_incompatible(...)
   14. vctrs:::stop_vctrs(...)
  
  ── 25. Error: .ptype is respected (@test-slide-period-vec.R#31)  ───────────────
  Can't convert <double> to <date>.
  Backtrace:
    1. testthat::expect_equal(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 26. Error: slide_period_chr() can coerce (@test-slide-period-vec.R#117)  ────
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equal(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 27. Error: inner type is allowed to be different (@test-slide-period2-vec.R#1
  Can't convert <double> to <list>.
  Backtrace:
    1. testthat::expect_equal(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 28. Failure: inner type can be restricted with list_of (@test-slide-period2-v
  `slide_period2_vec(...)` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <double> to <list_of<double>>.
  Backtrace:
    1. testthat::expect_error(...)
   10. vctrs::vec_default_cast(...)
   11. vctrs::stop_incompatible_cast(...)
   12. vctrs::stop_incompatible_type(...)
   13. vctrs:::stop_incompatible(...)
   14. vctrs:::stop_vctrs(...)
  
  ── 29. Error: .ptype is respected (@test-slide-period2-vec.R#31)  ──────────────
  Can't convert <double> to <date>.
  Backtrace:
    1. testthat::expect_equal(...)
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 30. Error: slide_period2_chr() can coerce (@test-slide-period2-vec.R#117)  ──
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equal(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 31. Error: inner type is allowed to be different (@test-slide-vec.R#12)  ────
  Can't convert <double> to <list>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 32. Failure: inner type can be restricted with list_of (@test-slide-vec.R#19)
  `slide_vec(...)` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <double> to <list_of<double>>.
  Backtrace:
    1. testthat::expect_error(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 33. Error: .ptype is respected (@test-slide-vec.R#31)  ──────────────────────
  Can't convert <double> to <date>.
  Backtrace:
    1. testthat::expect_equal(...)
    7. vctrs::vec_default_cast(...)
    8. vctrs::stop_incompatible_cast(...)
    9. vctrs::stop_incompatible_type(...)
   10. vctrs:::stop_incompatible(...)
   11. vctrs:::stop_vctrs(...)
  
  ── 34. Failure: names are not placed on data frames rownames (@test-slide-vec.R#
  rownames(out) not equal to c("1", "2").
  2/2 mismatches
  x[1]: "a"
  y[1]: "1"
  
  x[2]: "b"
  y[2]: "2"
  
  ── 35. Error: slide_chr() can coerce (@test-slide-vec.R#148)  ──────────────────
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equal(slide_chr(1, ~.x), "1")
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ── 36. Failure: row names are not extracted from data frames (@test-slide.R#471)
  names(slide(x, ~.x)) not equal to NULL.
  Types not compatible: character is not NULL
  
  ── 37. Failure: names are retained on inner sliced object (@test-slide.R#486)  ─
  slide(x, ~rownames(.x)) not equal to as.list(rownames(x)).
  names for target but not for current
  
  ── 38. Failure: cannot use invalid .before (@test-slide.R#499)  ────────────────
  `slide(1, identity, .before = "x")` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <character> to <integer>.
  Backtrace:
    1. testthat::expect_error(slide(1, identity, .before = "x"), class = "vctrs_error_cast_lossy")
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 39. Failure: cannot use invalid .after (@test-slide.R#504)  ─────────────────
  `slide(1, identity, .after = "x")` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <character> to <integer>.
  Backtrace:
    1. testthat::expect_error(slide(1, identity, .after = "x"), class = "vctrs_error_cast_lossy")
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 40. Failure: cannot use invalid .step (@test-slide.R#512)  ──────────────────
  `slide(1, identity, .step = "x")` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <character> to <integer>.
  Backtrace:
    1. testthat::expect_error(slide(1, identity, .step = "x"), class = "vctrs_error_cast_lossy")
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 41. Failure: cannot use invalid .complete (@test-slide.R#517)  ──────────────
  `slide(1, identity, .complete = "hi")` threw an error with unexpected class.
  Expected class: vctrs_error_cast_lossy
  Actual class:   vctrs_error_incompatible_type/vctrs_error_incompatible/vctrs_error/rlang_error/error/condition
  Message:        Can't convert <character> to <logical>.
  Backtrace:
    1. testthat::expect_error(...)
    9. vctrs::vec_default_cast(...)
   10. vctrs::stop_incompatible_cast(...)
   11. vctrs::stop_incompatible_type(...)
   12. vctrs:::stop_incompatible(...)
   13. vctrs:::stop_vctrs(...)
  
  ── 42. Error: slide2_chr() can coerce (@test-slide2-vec.R#48)  ─────────────────
  Can't convert <double> to <character>.
  Backtrace:
    1. testthat::expect_equivalent(slide2_chr(1, 1, ~.x + .y), "2")
    8. vctrs::vec_default_cast(...)
    9. vctrs::stop_incompatible_cast(...)
   10. vctrs::stop_incompatible_type(...)
   11. vctrs:::stop_incompatible(...)
   12. vctrs:::stop_vctrs(...)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  [ OK: 566 | SKIPPED: 9 | WARNINGS: 0 | FAILED: 42 ]
  1. Error: inner type is allowed to be different (@test-hop-index-vec.R#12) 
  2. Failure: inner type can be restricted with list_of (@test-hop-index-vec.R#19) 
  3. Error: .ptype is respected (@test-hop-index-vec.R#31) 
  4. Failure: names are not placed on data frames rownames (@test-hop-index-vec.R#122) 
  5. Error: inner type is allowed to be different (@test-hop-vec.R#12) 
  6. Failure: inner type can be restricted with list_of (@test-hop-vec.R#19) 
  7. Error: .ptype is respected (@test-hop-vec.R#31) 
  8. Failure: names are not placed on data frames rownames (@test-hop-vec.R#97) 
  9. Error: pslide_index_chr() can coerce (@test-pslide-index-vec.R#54) 
  1. ...
  
  Error: testthat unit tests failed
  Execution halted