Running ‘testthat.R’ [204s/220s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(brms)
  Loading required package: Rcpp
  Loading 'brms' package (version 2.8.0). Useful instructions
  can be found by typing help('brms'). A more detailed introduction
  to the package is available through vignette('brms_overview').
  > 
  > test_check("brms")
  ── 1. Error: plotting functions don't throw unexpected errors (@tests.plots.R#8)
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_silent(p <- plot(fit, plot = FALSE)) at testthat/tests.plots.R:8
  2: quasi_capture(enquo(object), evaluate_promise)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withr::with_output_sink(temp, withCallingHandlers(withVisible(code), warning = handle_warning, 
         message = handle_message))
  5: force(code)
  6: withCallingHandlers(withVisible(code), warning = handle_warning, message = handle_message)
  7: withVisible(code)
  8: eval_bare(get_expr(quo), get_env(quo))
  9: plot(fit, plot = FALSE)
  10: plot.brmsfit(fit, plot = FALSE)
  ...
  17: ggplot_gtable(ggplot_build(x))
  18: ggplot_gtable.ggplot_built(ggplot_build(x))
  19: layout$render(geom_grobs, data, theme, plot$labels)
  20: f(..., self = self)
  21: self$facet$draw_panels(panels, self$layout, self$panel_scales_x, self$panel_scales_y, 
         self$panel_params, self$coord, data, theme, self$facet_params)
  22: f(...)
  23: render_strips(structure(labels_df, type = "rows"), structure(labels_df, type = "cols"), 
         params$labeller, theme)
  24: build_strip(x, labeller, theme, TRUE)
  25: ggstrip(grobs, theme, element, gp, horizontal, clip = "on")
  26: Summary.unit(structure(c(3, 4), unit = 8L, class = c("margin", "unit")), na.rm = FALSE)
  
  ── 2. Failure: predict for categorical and related models runs without erros (@t
  rowSums(pred) not equal to rep(1, nrow(pred)).
  2/50 mismatches (average diff: NaN)
  [23] NaN - 1 == NaN
  [25] NaN - 1 == NaN
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  OK: 1289 SKIPPED: 4 FAILED: 2
  1. Error: plotting functions don't throw unexpected errors (@tests.plots.R#8) 
  2. Failure: predict for categorical and related models runs without erros (@tests.predict.R#308) 
  
  Error: testthat unit tests failed
  Execution halted