R Under development (unstable) (2024-06-17 r86768 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > attach(asNamespace("epigrowthfit")) > library(tools) > options(warn = 2L, error = if (interactive()) recover) > > > ## egf_enum ############################################################ > > ii <- Map(function(enum, type) egf_enum(c(enum, "invalid enum"), type), + enum = c("exponential", "pois", "norm"), + type = c("curve", "family", "prior")) > > for (i in ii) + stopifnot(exprs = { + is.integer(i) + length(i) == 2L + i[1L] >= 0L + i[2L] == -1L + }) > assertError(egf_enum(c("foo", "bar"), "invalid type")) > > proc.time() user system elapsed 1.21 0.20 1.40