Running ‘testthat.R’ [12s/13s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(ashr)
  > 
  > test_check("ashr")
  ── 1. Error: lik_binom (identity link) fitted g is close to true g (@test_binom.
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_binom(x, n), g = trueg) at testthat/test_binom.R:8
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 2. Error: lik_binom (identity link) fitted g is close to true g (@test_binom.
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_binom(x, n), mode = "estimate") at testthat/test_binom.R:23
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 3. Error: lik_binom (identity link) with big n gives similar answers to norma
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_binom(x, n)) at testthat/test_binom.R:39
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 4. Error: lik_binom (logit link) fitted g is close to true g (@test_binom.R#5
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_binom(x, n, link = "logit"), g = trueg, prior = "uniform") at testthat/test_binom.R:59
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 5. Error: lik_binom (logit link) fitted g is close to true g (@test_binom.R#7
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_binom(x, n, link = "logit"), mode = "estimate") at testthat/test_binom.R:75
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 6. Error: df switches (@test_df.R#8)  ───────────────────────────────────────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash.workhorse(betahat = betahat[1:5], sebetahat = sebetahat[1:5], df = Inf) at testthat/test_df.R:8
  2: estimate_mixprop(data, g, prior, optmethod = optmethod, control = control, weights = weights)
  3: do.call(optmethod, args = list(matrix_lik = matrix_lik, prior = prior, pi_init = pi_init, 
         control = control))
  4: mixIP(matrix_lik = structure(c(1, 0.000993141072021091, 0.751594138244189, 0.480506102213957, 
     0.000127752493421005, 0.999999300351534, 0.00099571957030837, 0.751760654933696, 
     0.480630988938211, 0.000130456679523104, 0.999998598989935, 0.000998301045853174, 
     0.751927093803026, 0.480755857804589, 0.000133188181772012, 0.999997191128138, 0.00100347293448217, 
     0.752259738176577, 0.481005541964548, 0.000138733698076604, 0.999994354856764, 0.00101385250226441, 
     0.752924094130841, 0.481504695999367, 0.000150158737216649, 0.999988600174233, 0.00103475512283547, 
     0.75424908020497, 0.48250214697765, 0.000174376751015297, 0.999976762661325, 0.00107713688689031, 
     0.756884191648695, 0.484493620971243, 0.000228543519674271, 0.999951778328632, 0.00116422716300056, 
     0.762095311780531, 0.488462860486869, 0.000361930407957411, 0.999896598627926, 0.0013478798337255, 
     0.772283845447586, 0.496346535221033, 0.000746854177007261, 0.999765603283405, 0.00175439215142833, 
     0.791747463447666, 0.511894944155507, 0.0021456188623168, 0.99942271318594, 0.00273473614619273, 
     0.827187755754853, 0.542118827105042, 0.00885923754792946, 0.998426157226074, 0.00544722153622918, 
     0.885388330995896, 0.599106527486294, 0.0495488596988368, 0.995287390161415, 0.0145020567402157, 
     0.96014810780001, 0.699617542159869, 0.28745254866477, 0.985130856241669, 0.0511315742895792, 
     1, 0.851152252268936, 0.936445159851178, 0.953887393443776, 0.208862597987872, 0.906270108894674, 
     1, 1, 0.872006311422054, 0.680460592523044, 0.687845499733546, 0.985720228868147, 
     0.711621030875185, 0.715088568208871, 1, 0.488122544115151, 0.765289750680224, 0.503192069838324, 
     0.525333800107958, 0.75440198569814, 0.345156430854286, 0.543351149872505, 0.355810524821973
     ), .Dim = c(5L, 18L)), prior = c(10, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 
     1, 1), pi_init = c(0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 
     0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 
     0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 
     0.0555555555555556, 0.0555555555555556, 0.0555555555555556, 0.0555555555555556), 
         control = list())
  5: check_mosek_license()
  6: tryCatch({
         out <- Rmosek::mosek(x, opts = list(verbose = 0))
         if (out$response$code != 0) 
             stop(paste("MOSEK is installed, but failed to run. A common issue is that\n", 
                 "the license is expired unavailable. To troubleshoot, see:\n", "https://github.com/stephens999/ashr/blob/master/inst/rmosek-mac.md\n", 
                 "https://github.com/stephens999/ashr/blob/master/inst/rmosek-linux.md"))
     })
  7: tryCatchList(expr, classes, parentenv, handlers)
  8: Rmosek::mosek
  9: getExportedValue(pkg, name)
  10: stop(gettextf("'%s' is not an exported object from 'namespace:%s'", name, getNamespaceName(ns)), 
         call. = FALSE, domain = NA)
  
  ── 7. Error: PosteriorMean is equal to weighted component-specific posterior mea
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1, outputlevel = 4) at testthat/test_flashdata.R:2
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 8. Error: PosteriorSD squared is equal to weighted component mean2 minus post
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1, outputlevel = 4, mixcompdist = "normal") at testthat/test_flashdata.R:6
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 9. Error: comp_postmean for null component is 0 (@test_flashdata.R#11)  ─────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1, outputlevel = 4, mixcompdist = "normal") at testthat/test_flashdata.R:11
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 10. Error: comp_postmean for missing data is 0 (@test_flashdata.R#16)  ──────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(c(NA, z), 1, outputlevel = 4) at testthat/test_flashdata.R:16
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 11. Error: comp_postprob for missing data is fitted pi (@test_flashdata.R#21)
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(c(NA, z), 1, outputlevel = 4) at testthat/test_flashdata.R:21
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 12. Error: prior is returned with correct components for flash data (@test_fl
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1, method = "fdr", outputlevel = 5, pi_thresh = 1e-06) at testthat/test_flashdata.R:26
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 13. Error: logF error with df=(10,10) gives similar answers to normal error (
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(x, s) at testthat/test_logF.R:13
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 14. Error: sum of calc_vlogLR is same as calc_logLR (@test_loglik.R#52)  ────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ashr::ash(z, 1, df = 4) at testthat/test_loglik.R:52
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 15. Error: missing data don't change results (@test_missing.R#4)  ───────────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, s) at testthat/test_missing.R:4
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 16. Error: ash mode 1 gives same results as mode 0 but shifted by 1 (@test_mo
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1) at testthat/test_mode.R:22
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 17. Error: new results match old ones  (@test_old_vs_new.R#6)  ──────────────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1) at testthat/test_old_vs_new.R:6
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 18. Error: control is passed to optmethod correctly when method is mixIP (@te
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1, control = list(rtol = 0.1), outputlevel = 3) at testthat/test_optmethod.R:17
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 19. Error: lik_pois (identity link) fitted g is close to true g (@test_pois.R
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_pois(x), g = trueg) at testthat/test_pois.R:7
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 20. Error: lik_pois (identity link) fitted mode is close to true mode (@test_
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_pois(x), mode = "estimate") at testthat/test_pois.R:20
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 21. Error: lik_pois (identity link) with high intensities gives similar answe
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_pois(x)) at testthat/test_pois.R:35
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 22. Error: lik_pois (log link) fitted g is close to true g (@test_pois.R#54) 
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_pois(x, link = "log"), g = trueg) at testthat/test_pois.R:54
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 23. Error: lik_pois (log link) fitted mode is close to true mode (@test_pois.
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(rep(0, length(x)), 1, lik = lik_pois(x, link = "log"), mode = "estimate") at testthat/test_pois.R:68
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 24. Error: get_post_sample works as expected (@test_postsample.R#7)  ────────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, se, "normal") at testthat/test_postsample.R:7
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 25. Error: test pruning with and without flash  (@test_prune.R#14)  ─────────
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1, outputlevel = 4) at testthat/test_prune.R:14
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 26. Error: ash with automatic truncfun gives similar answers to default (@tes
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1) at testthat/test_truncgen.R:22
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ── 27. Error: optimization with weights matches expectations (@test_w_mixEM.R#8)
  'mosek' is not an exported object from 'namespace:Rmosek'
  1: ash(z, 1, optmethod = "mixIP", weights = c(rep(1, 50), rep(0, 50)), g = get_fitted_g(z.ash)) at testthat/test_w_mixEM.R:8
  2: utils::modifyList(ash.workhorse(betahat, sebetahat, mixcompdist = mixcompdist, df = df, 
         ...), list(call = match.call()))
  3: stopifnot(is.list(x), is.list(val))
  4: withCallingHandlers(tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), 
         error = function(e) {
             e$call <- cl.i
             stop(e)
         }), warning = function(w) {
         w$call <- cl.i
         w
     })
  5: tryCatch(if (missE) ...elt(i) else eval(cl.i, envir = envir), error = function(e) {
         e$call <- cl.i
         stop(e)
     })
  6: tryCatchList(expr, classes, parentenv, handlers)
  7: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  8: value[[3L]](cond)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  OK: 81 SKIPPED: 1 FAILED: 27
  1. Error: lik_binom (identity link) fitted g is close to true g (@test_binom.R#8) 
  2. Error: lik_binom (identity link) fitted g is close to true g (@test_binom.R#23) 
  3. Error: lik_binom (identity link) with big n gives similar answers to normal likelihood (@test_binom.R#39) 
  4. Error: lik_binom (logit link) fitted g is close to true g (@test_binom.R#59) 
  5. Error: lik_binom (logit link) fitted g is close to true g (@test_binom.R#75) 
  6. Error: df switches (@test_df.R#8) 
  7. Error: PosteriorMean is equal to weighted component-specific posterior means (@test_flashdata.R#2) 
  8. Error: PosteriorSD squared is equal to weighted component mean2 minus posterior mean all squared (@test_flashdata.R#6) 
  9. Error: comp_postmean for null component is 0 (@test_flashdata.R#11) 
  1. ...
  
  Error: testthat unit tests failed
  Execution halted