test_inherits: Check class of object

View source: R/test.R

test_inheritsR Documentation

Check class of object

Description

Check class of object

Usage

test_inherits(x, cl)

Arguments

x

Object to check

cl

Character: class to check against

Value

Logical

Author(s)

EDG

Examples

test_inherits("papaya", "character") # TRUE
test_inherits(c(1, 2.5, 3.2), "integer")
test_inherits(iris, "list") # FALSE, compare to is_check(iris, is.list)

rtemis.core documentation built on April 22, 2026, 1:11 a.m.