Class ProtoModelColumnAssertions<TValue>

Namespace
ProtoTest.Sheets
Assembly
ProtoTest.Sheets.dll

The Should/ShouldNot surface of a typed model column. The comparison is written once and runs with the polarity of the property that produced this facade.

public sealed class ProtoModelColumnAssertions<TValue>

Type Parameters

TValue
Inheritance
ProtoModelColumnAssertions<TValue>
Inherited Members
Extension Methods

Methods

All(Func<TValue?, bool>)

Checks every value against a property, for example every amount above zero, and returns the column. A negated assertion passes when at least one value does not match.

public ProtoModelColumn<TValue> All(Func<TValue?, bool> predicate)

Parameters

predicate Func<TValue, bool>

Returns

ProtoModelColumn<TValue>

Be(IReadOnlyList<TValue?>)

Compares the column's values against the expected sequence, top to bottom, and returns the column.

public ProtoModelColumn<TValue> Be(IReadOnlyList<TValue?> expected)

Parameters

expected IReadOnlyList<TValue>

Returns

ProtoModelColumn<TValue>

BeSortedBy(ProtoSortDirection)

Checks the values are ordered in the requested direction. Returns the column.

public ProtoModelColumn<TValue> BeSortedBy(ProtoSortDirection direction = ProtoSortDirection.Ascending)

Parameters

direction ProtoSortDirection

Returns

ProtoModelColumn<TValue>