Usage
check_proportion(x, null.ok = FALSE)
assert_proportion(
x,
null.ok = FALSE,
.var.name = checkmate::vname(x),
add = NULL
)
test_proportion(x, null.ok = FALSE)
expect_proportion(x, null.ok = FALSE, info = NULL, label = vname(x))
Arguments
- x
an object to check.
- null.ok
(
flag
)
whetherx
may also beNULL
.- .var.name
(
string
)
name of the checked object to print in assertions; defaults to the heuristic implemented incheckmate::vname()
.- add
(
AssertCollection
orNULL
)
collection to store assertion messages, seecheckmate::AssertCollection
.- info
(
string
)
extra information to be included in the message for thetestthat
reporter, seetestthat::expect_that()
.- label
(
string
)
name of the checked object to print in messages. Defaults to the heuristic implemented incheckmate::vname()
.
See also
assertions
for more details.