Code coverage improvements · Pull Request #2180 · fluentassertions/fluentassertions · GitHub
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions Tests/FluentAssertions.Equivalency.Specs/DataColumnSpecs.cs
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,24 @@ public void When_DataColumn_has_changes_but_is_excluded_it_should_succeed()
.ExcludingColumn(dataColumn2));
}

[Fact]
public void Can_exclude_a_column_from_all_tables()
{
// Arrange
var subjectDataSet = CreateDummyDataSet<TypedDataSetSubclass>();
var expectationDataSet = new TypedDataSetSubclass(subjectDataSet);

var subject = subjectDataSet.TypedDataTable1.DecimalColumn;
var expectation = expectationDataSet.TypedDataTable1.DecimalColumn;

expectation.Unique = true;
expectation.Caption = "Test";

// Act & Assert
subject.Should().BeEquivalentTo(expectation, options => options
.ExcludingColumnInAllTables(expectation.ColumnName));
}

[Fact]
public void When_DataColumn_has_changes_but_is_excluded_as_params_it_should_succeed()
{
Expand Down
18 changes: 18 additions & 0 deletions Tests/FluentAssertions.Equivalency.Specs/DataTableSpecs.cs