expectation
, and signal
an expectation with expect
. If you're making your own expectation
function, you'll typically call expect(condition, "failure message")
.
See the source code for the built-in expectations for details.expectation(type, message, srcref = NULL)expect(exp, ..., srcref = NULL)
is.expectation(x)
TRUE
), failed (FALSE
), or threw an error (NA
)