Running 'testthat.R' [16s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(MADPop)
  Loading required package: rstan
  Loading required package: StanHeaders
  Loading required package: ggplot2
  rstan (Version 2.21.2, GitRev: 2e1f913d3ca3)
  For execution on a local, multicore CPU with excess RAM we recommend calling
  options(mc.cores = parallel::detectCores()).
  To avoid recompilation of unchanged Stan programs, we recommend calling
  rstan_options(auto_write = TRUE)
  Do not specify '-march=native' in 'LOCAL_CPPFLAGS' or a Makevars file
  > 
  > test_check("MADPop")
  
  SAMPLING FOR MODEL 'DirichletMultinomial' NOW (CHAIN 1).
  Chain 1: 
  Chain 1: Gradient evaluation took 0 seconds
  Chain 1: 1000 transitions using 10 leapfrog steps per transition would take 0 seconds.
  Chain 1: Adjust your expectations accordingly!
  Chain 1: 
  Chain 1: 
  Chain 1: WARNING: There aren't enough warmup iterations to fit the
  Chain 1:          three stages of adaptation as currently configured.
  Chain 1:          Reducing each adaptation stage to 15%/75%/10% of
  Chain 1:          the given number of warmup iterations:
  Chain 1:            init_buffer = 7
  Chain 1:            adapt_window = 38
  Chain 1:            term_buffer = 5
  Chain 1: 
  Chain 1: Iteration:  1 / 100 [  1%]  (Warmup)
  Chain 1: Iteration: 10 / 100 [ 10%]  (Warmup)
  Chain 1: Iteration: 20 / 100 [ 20%]  (Warmup)
  Chain 1: Iteration: 30 / 100 [ 30%]  (Warmup)
  Chain 1: Iteration: 40 / 100 [ 40%]  (Warmup)
  Chain 1: Iteration: 50 / 100 [ 50%]  (Warmup)
  Chain 1: Iteration: 51 / 100 [ 51%]  (Sampling)
  Chain 1: Iteration: 60 / 100 [ 60%]  (Sampling)
  Chain 1: Iteration: 70 / 100 [ 70%]  (Sampling)
  Chain 1: Iteration: 80 / 100 [ 80%]  (Sampling)
  Chain 1: Iteration: 90 / 100 [ 90%]  (Sampling)
  Chain 1: Iteration: 100 / 100 [100%]  (Sampling)
  Chain 1: 
  Chain 1:  Elapsed Time: 7.098 seconds (Warm-up)
  Chain 1:                3.276 seconds (Sampling)
  Chain 1:                10.374 seconds (Total)
  Chain 1: 
  -- Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`) -------
  There were 47 divergent transitions after warmup. See
  http://mc-stan.org/misc/warnings.html#divergent-transitions-after-warmup
  to find out why this is a problem and how to eliminate them.
  
  -- Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`) -------
  There were 3 transitions after warmup that exceeded the maximum treedepth. Increase max_treedepth above 10. See
  http://mc-stan.org/misc/warnings.html#maximum-treedepth-exceeded
  
  -- Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`) -------
  Examine the pairs() plot to diagnose sampling problems
  
  
  -- Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`) -------
  The largest R-hat is NA, indicating chains have not mixed.
  Running the chains for more iterations may help. See
  http://mc-stan.org/misc/warnings.html#r-hat
  
  -- Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`) -------
  Bulk Effective Samples Size (ESS) is too low, indicating posterior means and medians may be unreliable.
  Running the chains for more iterations may help. See
  http://mc-stan.org/misc/warnings.html#bulk-ess
  
  -- Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`) -------
  Tail Effective Samples Size (ESS) is too low, indicating posterior variances and tail quantiles may be unreliable.
  Running the chains for more iterations may help. See
  http://mc-stan.org/misc/warnings.html#tail-ess
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 64 - 0 == 64
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 32 - 0 == 32
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 64 - 0 == 64
  
  -- FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan -----------------
  max_diff[ii] not equal to 0.
  1/1 mismatches
  [1] 64 - 0 == 64
  
  == testthat results  ===========================================================
  Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`)
  Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`)
  Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`)
  Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`)
  Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`)
  Warning (test-stanmodels.R:12:1): (code run outside of `test_that()`)
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  FAILURE (test-stanmodels.R:36:5): logpost_R == logpost_Stan
  
  [ FAIL 11 | WARN 6 | SKIP 0 | PASS 38 ]
  Error: Test failures
  Execution halted