Running ‘testthat.R’ [44s/55s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(posterior)
  This is posterior version 1.4.1
  
  Attaching package: 'posterior'
  
  The following objects are masked from 'package:stats':
  
      mad, sd, var
  
  The following objects are masked from 'package:base':
  
      %in%, match
  
  > 
  > test_check("posterior")
  [ FAIL 15 | WARN 0 | SKIP 5 | PASS 1468 ]
  
  ══ Skipped tests (5) ═══════════════════════════════════════════════════════════
  • On CRAN (5): 'test-print.R:55:3', 'test-print.R:114:3', 'test-rstar.R:108:3',
    'test-rvar-print.R:207:3', 'test-subset_draws.R:134:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Failure ('test-rvar-bind.R:156:3'): cbind works on rvar ─────────────────────
  cbind(x, y, deparse.level = 0) not equal to rvar(array(c(1:9, 2:10), dim = c(3, 3, 2))).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: Modes: character, NULL > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: target is character, current is NULL > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:157:3'): cbind works on rvar ─────────────────────
  cbind(a = x, y, deparse.level = 0) not equal to rvar(...).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: 2 string mismatches > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:163:3'): cbind works on rvar ─────────────────────
  cbind(x, b = y, deparse.level = 0) not equal to rvar(...).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: 2 string mismatches > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:166:3'): cbind works on rvar ─────────────────────
  cbind(x, y + 1, deparse.level = 2) not equal to rvar(...).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: 2 string mismatches > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:169:3'): cbind works on rvar ─────────────────────
  cbind(x, y, y + 1, deparse.level = 2) not equal to rvar(...).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.25 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: 3 string mismatches > >
  Attributes: < Component "draws": Numeric: lengths (36, 27) differ >
  ── Failure ('test-rvar-bind.R:176:3'): cbind works on rvar ─────────────────────
  cbind(x_col, y, deparse.level = 0) not equal to rvar(array(c(1:9, 2:10), dim = c(3, 3, 2))).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: Modes: character, NULL > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: target is character, current is NULL > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Error ('test-rvar-bind.R:196:3'): cbind works on rvar_factor ────────────────
  Error in `nax != nay`: non-conformable arrays
  Backtrace:
       ▆
    1. └─testthat::expect_equal(...) at test-rvar-bind.R:196:2
    2.   ├─testthat::compare(act$val, exp$val, ...)
    3.   └─testthat:::compare.default(act$val, exp$val, ...)
    4.     ├─base::all.equal(x, y, ...)
    5.     └─posterior:::all.equal.rvar(x, y, ...)
    6.       ├─base::all.equal(.target, .current, ...)
    7.       └─base::all.equal.list(.target, .current, ...)
    8.         └─base::attr.all.equal(target, current, ...)
    9.           ├─base::all.equal(ax, ay, ..., check.attributes = check.attributes)
   10.           └─base::all.equal.list(ax, ay, ..., check.attributes = check.attributes)
   11.             ├─base::all.equal(...)
   12.             └─base::all.equal.factor(...)
  ── Failure ('test-rvar-bind.R:254:3'): rbind works on rvar ─────────────────────
  rbind(x, y, deparse.level = 0) not equal to rvar(x_y_array).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 2: Modes: character, NULL > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 2: target is character, current is NULL > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:255:3'): rbind works on rvar ─────────────────────
  rbind(a = x, y, deparse.level = 0) not equal to rvar(x_y_array, dimnames = list(c("a", ""), NULL)).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 2: 2 string mismatches > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:257:3'): rbind works on rvar ─────────────────────
  rbind(x, b = y, deparse.level = 0) not equal to rvar(x_y_array, dimnames = list(c("", "b"), NULL)).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 2: 2 string mismatches > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:258:3'): rbind works on rvar ─────────────────────
  rbind(x, y + 1, deparse.level = 2) not equal to rvar(x_yp1_array, dimnames = list(c("x", "y + 1"), NULL)).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 2: 2 string mismatches > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Failure ('test-rvar-bind.R:263:3'): rbind works on rvar ─────────────────────
  rbind(x_row, y, deparse.level = 0) not equal to rvar(x_y_array).
  Attributes: < Component "draws": Attributes: < Component "dim": Mean relative difference: 0.3333333 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 2: Modes: character, NULL > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 2: target is character, current is NULL > >
  Attributes: < Component "draws": Numeric: lengths (27, 18) differ >
  ── Error ('test-rvar-bind.R:286:3'): rbind works on rvar_factor ────────────────
  Error in `nax != nay`: non-conformable arrays
  Backtrace:
       ▆
    1. └─testthat::expect_equal(rbind(x, y, deparse.level = 0), rvar_factor(x_y_array)) at test-rvar-bind.R:286:2
    2.   ├─testthat::compare(act$val, exp$val, ...)
    3.   └─testthat:::compare.default(act$val, exp$val, ...)
    4.     ├─base::all.equal(x, y, ...)
    5.     └─posterior:::all.equal.rvar(x, y, ...)
    6.       ├─base::all.equal(.target, .current, ...)
    7.       └─base::all.equal.list(.target, .current, ...)
    8.         └─base::attr.all.equal(target, current, ...)
    9.           ├─base::all.equal(ax, ay, ..., check.attributes = check.attributes)
   10.           └─base::all.equal.list(ax, ay, ..., check.attributes = check.attributes)
   11.             ├─base::all.equal(...)
   12.             └─base::all.equal.factor(...)
  ── Failure ('test-rvar-math.R:311:3'): Cholesky decomposition works ────────────
  chol(Sigma) not equal to rdo(chol(Sigma)).
  Attributes: < Component "draws": Attributes: < Component "dimnames": names for target but not for current > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: Modes: character, NULL > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: Lengths: 3, 0 > >
  Attributes: < Component "draws": Attributes: < Component "dimnames": Component 3: target is character, current is NULL > >
  ── Failure ('test-rvar-slice.R:141:3'): indexing with [ works on a vector ──────
  x[NULL] not equal to new_rvar(array(numeric(), dim = c(5, 0))).
  Attributes: < Component "draws": Attributes: < Component "dimnames": names for target but not for current > >
  
  [ FAIL 15 | WARN 0 | SKIP 5 | PASS 1468 ]
  Error: Test failures
  Execution halted