Learn R Programming

testextra (version 0.1.0.1)

validity-tests: Alternate check for validity

Description

These functions will test if an object is valid returning a value appropriate to use in assertthat::validate_that(), assertthat::assert_that(), or assertthat::see_if().

Usage

is_valid(object, complete = FALSE)

are_valid(lst, complete = FALSE)

Arguments

object

an S4 object to test for validity

complete

logical; if TRUE, validObject is called recursively for each of the slots. The default is FALSE.

lst

a list of S4 objects to test for validity.

Functions

  • is_valid: Check if an object is valid.

  • are_valid: Check if each element in a list is valid.

See Also

Other validity-tests: expect_valid