assertTrue: Assert that an expression is TRUE.

View source: R/assert.R

assertTrueR Documentation

Assert that an expression is TRUE.

Description

Assert that an expression is TRUE.

Usage

assertTrue(
  x,
  null = FALSE,
  empty = TRUE,
  nm = deparse1(substitute(x), backtick = TRUE),
  call = parent.frame(),
  msg = NULL
)

Arguments

x

Expression to check.

null

Whether it can be NULL.

empty

Whether it can be empty.

nm

Name to use in error messages. Defaults to the expression supplied to x.

call

Call argument that will be passed to cli.

msg

Custom error message.


omopgenerics documentation built on June 17, 2026, 5:07 p.m.