Running ‘testthat.R’ [7s/11s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(descriptr)
  > 
  > test_check("descriptr")
  ── 1. Error: dist_binom_plot throws the appropriate warning (@test-binom-dist.R#
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_binom_plot(10, 0.3), "vistributions") at testthat/test-binom-dist.R:4
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_binom_plot(10, 0.3)
  7: print(vistributions::vdist_binom_plot(n, p))
  8: print.ggplot(vistributions::vdist_binom_plot(n, p))
  9: grid.draw(gtable)
  10: grid.draw.gTree(gtable)
  ...
  13: preDraw(x)
  14: preDraw.gTree(x)
  15: pushvpgp(x)
  16: pushgrobvp(x$vp)
  17: pushgrobvp.viewport(x$vp)
  18: pushViewport(vp, recording = FALSE)
  19: lapply(vps, push.vp, recording)
  20: FUN(X[[i]], ...)
  21: push.vp.viewport(X[[i]], ...)
  22: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 2. Error: dist_binom_prob throws the appropriate warning (@test-binom-dist.R#
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_binom_prob(10, 0.3, 4, type = "exact"), "vistributions") at testthat/test-binom-dist.R:8
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_binom_prob(10, 0.3, 4, type = "exact")
  7: print(vistributions::vdist_binom_prob(n, p, s, type))
  8: print.ggplot(vistributions::vdist_binom_prob(n, p, s, type))
  9: grid.draw(gtable)
  10: grid.draw.gTree(gtable)
  ...
  13: preDraw(x)
  14: preDraw.gTree(x)
  15: pushvpgp(x)
  16: pushgrobvp(x$vp)
  17: pushgrobvp.viewport(x$vp)
  18: pushViewport(vp, recording = FALSE)
  19: lapply(vps, push.vp, recording)
  20: FUN(X[[i]], ...)
  21: push.vp.viewport(X[[i]], ...)
  22: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 3. Error: dist_binom_perc throws the appropriate warning (@test-binom-dist.R#
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_binom_perc(10, 0.5, 0.05), "vistributions") at testthat/test-binom-dist.R:12
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_binom_perc(10, 0.5, 0.05)
  7: print(vistributions::vdist_binom_perc(n, p, tp, type))
  8: print.ggplot(vistributions::vdist_binom_perc(n, p, tp, type))
  9: grid.draw(gtable)
  10: grid.draw.gTree(gtable)
  ...
  13: preDraw(x)
  14: preDraw.gTree(x)
  15: pushvpgp(x)
  16: pushgrobvp(x$vp)
  17: pushgrobvp.viewport(x$vp)
  18: pushViewport(vp, recording = FALSE)
  19: lapply(vps, push.vp, recording)
  20: FUN(X[[i]], ...)
  21: push.vp.viewport(X[[i]], ...)
  22: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 4. Error: dist_chi_prob throws the appropriate warning (@test-chi-dist.R#8)  
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_chi_prob(13.58, 11, "lower"), "vistributions") at testthat/test-chi-dist.R:8
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_chi_prob(13.58, 11, "lower")
  7: print(vistributions::vdist_chisquare_prob(perc, df, type))
  8: print.ggplot(vistributions::vdist_chisquare_prob(perc, df, type))
  9: grid.draw(gtable)
  10: grid.draw.gTree(gtable)
  ...
  13: preDraw(x)
  14: preDraw.gTree(x)
  15: pushvpgp(x)
  16: pushgrobvp(x$vp)
  17: pushgrobvp.viewport(x$vp)
  18: pushViewport(vp, recording = FALSE)
  19: lapply(vps, push.vp, recording)
  20: FUN(X[[i]], ...)
  21: push.vp.viewport(X[[i]], ...)
  22: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 5. Error: dist_chi_perc throws the appropriate warning (@test-chi-dist.R#12) 
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_chi_perc(0.165, 8, "upper"), "vistributions") at testthat/test-chi-dist.R:12
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_chi_perc(0.165, 8, "upper")
  7: print(vistributions::vdist_chisquare_perc(probs, df, type))
  8: print.ggplot(vistributions::vdist_chisquare_perc(probs, df, type))
  9: grid.draw(gtable)
  10: grid.draw.gTree(gtable)
  ...
  13: preDraw(x)
  14: preDraw.gTree(x)
  15: pushvpgp(x)
  16: pushgrobvp(x$vp)
  17: pushgrobvp.viewport(x$vp)
  18: pushViewport(vp, recording = FALSE)
  19: lapply(vps, push.vp, recording)
  20: FUN(X[[i]], ...)
  21: push.vp.viewport(X[[i]], ...)
  22: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 6. Error: dist_f_plot throws the appropriate warning (@test-f-dist.R#5)  ────
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_f_plot(), "vistributions") at testthat/test-f-dist.R:5
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_f_plot()
  7: vistributions::vdist_f_plot(num_df, den_df, normal)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 7. Error: dist_f_prob throws the appropriate warning (@test-f-dist.R#9)  ────
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_f_prob(2.35, 5, 32), "vistributions") at testthat/test-f-dist.R:9
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_f_prob(2.35, 5, 32)
  7: vistributions::vdist_f_prob(perc, num_df, den_df, type)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 8. Error: dist_f_perc throws the appropriate warning (@test-f-dist.R#13)  ───
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_f_perc(0.95, 3, 30, "lower"), "vistributions") at testthat/test-f-dist.R:13
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_f_perc(0.95, 3, 30, "lower")
  7: vistributions::vdist_f_perc(probs, num_df, den_df, type)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 9. Error: dist_norm_plot throws the appropriate warning (@test-normal-dist.R#
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_norm_plot(), "vistributions") at testthat/test-normal-dist.R:4
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_norm_plot()
  7: vistributions::vdist_normal_plot(mean, sd)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 10. Error: dist_norm_prob throws the appropriate warning (@test-normal-dist.R
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_norm_prob(3.78, mean = 2, sd = 1.36), "vistributions") at testthat/test-normal-dist.R:8
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_norm_prob(3.78, mean = 2, sd = 1.36)
  7: vistributions::vdist_normal_prob(perc, mean, sd, type)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 11. Error: dist_norm_perc throws the appropriate warning (@test-normal-dist.R
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_norm_perc(0.95, mean = 2, sd = 1.36), "vistributions") at testthat/test-normal-dist.R:12
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_norm_perc(0.95, mean = 2, sd = 1.36)
  7: vistributions::vdist_normal_perc(probs, mean, sd, type)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 12. Error: dist_t_plot throws the appropriate warning (@test-t-dist.R#4)  ───
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_t_plot(), "vistributions") at testthat/test-t-dist.R:4
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_t_plot()
  7: vistributions::vdist_t_plot(df)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 13. Error: dist_t_prob throws the appropriate warning (@test-t-dist.R#8)  ───
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_t_prob(2.045, 7, "lower"), "vistributions") at testthat/test-t-dist.R:8
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_t_prob(2.045, 7, "lower")
  7: vistributions::vdist_t_prob(perc, df, type)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ── 14. Error: dist_t_perc throws the appropriate warning (@test-t-dist.R#12)  ──
  VECTOR_ELT() can only be applied to a 'list', not a 'double'
  1: expect_warning(dist_t_perc(probs = 0.95, df = 4, type = "lower"), "vistributions") at testthat/test-t-dist.R:12
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: dist_t_perc(probs = 0.95, df = 4, type = "lower")
  7: vistributions::vdist_t_perc(probs, df, type)
  8: print(gplot)
  9: print.ggplot(gplot)
  10: grid.draw(gtable)
  ...
  14: preDraw(x)
  15: preDraw.gTree(x)
  16: pushvpgp(x)
  17: pushgrobvp(x$vp)
  18: pushgrobvp.viewport(x$vp)
  19: pushViewport(vp, recording = FALSE)
  20: lapply(vps, push.vp, recording)
  21: FUN(X[[i]], ...)
  22: push.vp.viewport(X[[i]], ...)
  23: grid.Call.graphics(C_setviewport, vp, TRUE)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  OK: 243 SKIPPED: 4 FAILED: 14
  1. Error: dist_binom_plot throws the appropriate warning (@test-binom-dist.R#4) 
  2. Error: dist_binom_prob throws the appropriate warning (@test-binom-dist.R#8) 
  3. Error: dist_binom_perc throws the appropriate warning (@test-binom-dist.R#12) 
  4. Error: dist_chi_prob throws the appropriate warning (@test-chi-dist.R#8) 
  5. Error: dist_chi_perc throws the appropriate warning (@test-chi-dist.R#12) 
  6. Error: dist_f_plot throws the appropriate warning (@test-f-dist.R#5) 
  7. Error: dist_f_prob throws the appropriate warning (@test-f-dist.R#9) 
  8. Error: dist_f_perc throws the appropriate warning (@test-f-dist.R#13) 
  9. Error: dist_norm_plot throws the appropriate warning (@test-normal-dist.R#4) 
  1. ...
  
  Error: testthat unit tests failed
  Execution halted