<PackageReference Include="NUnit" Version="2.6.4" />

Has

public class Has
Helper class with properties and methods that supply a number of constraints used in Asserts.
public static ConstraintExpression All { get; }

Returns a ConstraintExpression, which will apply the following constraint to all members of a collection, succeeding if all of them succeed.

public static ResolvableConstraintExpression Count { get; }

Returns a new ConstraintExpression, which will apply the following constraint to the Count property of the object being tested.

Returns a new ConstraintExpression, which will apply the following constraint to the InnerException property of the object being tested.

public static ResolvableConstraintExpression Length { get; }

Returns a new ConstraintExpression, which will apply the following constraint to the Length property of the object being tested.

public static ResolvableConstraintExpression Message { get; }

Returns a new ConstraintExpression, which will apply the following constraint to the Message property of the object being tested.

public static ConstraintExpression No { get; }

Returns a ConstraintExpression that negates any following constraint.

public static ConstraintExpression None { get; }

Returns a ConstraintExpression, which will apply the following constraint to all members of a collection, succeeding if all of them fail.

public static ConstraintExpression Some { get; }

Returns a ConstraintExpression, which will apply the following constraint to all members of a collection, succeeding if at least one of them succeeds.

public Has()

public static ResolvableConstraintExpression Attribute(Type expectedType)

Returns a new AttributeConstraint checking for the presence of a particular attribute on an object.

Returns a new AttributeConstraint checking for the presence of a particular attribute on an object.

public static ConstraintExpression Exactly(int expectedCount)

Returns a ConstraintExpression, which will apply the following constraint to all members of a collection, succeeding only if a specified number of them succeed.

public static CollectionContainsConstraint Member(object expected)

Returns a new CollectionContainsConstraint checking for the presence of a particular object in the collection.

public static ResolvableConstraintExpression Property(string name)

Returns a new PropertyConstraintExpression, which will either test for the existence of the named property on the object being tested or apply any following constraint to that property.