matlab.unittest.constraints.IsSupersetOf Class
Namespace: matlab.unittest.constraints
Superclasses: matlab.unittest.constraints.BooleanConstraint
Test if set is superset of specified set
Description
The matlab.unittest.constraints.IsSupersetOf
class provides a constraint to
test if a set is a superset of another set.
The constraint uses the ismember
function to compare sets. So, the
actual and expected values you use with the constraint must be supported by the
ismember
function.
Creation
Description
c = matlab.unittest.constraints.IsSupersetOf(subset)
creates a constraint to test if a set is a superset of the specified subset and sets the
Subset
property. For an actual set actual
, the
constraint is satisfied if ismember(subset,actual)
returns an array
that contains all true
values and at least one of these conditions is met:
actual
andsubset
are of the same class.isobject(actual)
returnstrue
.isobject(subset)
returnstrue
.
Properties
Examples
Version History
Introduced in R2016a