Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.
/ corefx Public archive

Label implements IEquatable<Label> #35673

Merged
merged 5 commits into from
Apr 6, 2019
Merged
Changes from 1 commit
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
Prev Previous commit
Merge IEquatable unit tests with existing equality tests
  • Loading branch information
foxtrek64 committed Apr 3, 2019
commit 287b8be6f8c13367db51e009d50ec455fb50e336
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ public void Equals_SameInstance_ReturnsTrue()
Label label = new Label();
Assert.True(label.Equals(label));
Assert.True(label.Equals((object)label));
Assert.True(label.Equals((IEquatable<Label>)label));
}

[Fact]
Expand All @@ -27,6 +28,7 @@ public void Equals_DifferentLabel_ReturnsFalse()

Assert.False(label1.Equals(label2));
Assert.False(label1.Equals((object)label2));
Assert.False(label1.Equals((IEquatable<Label>)label2));
}

[Theory]
Expand All @@ -49,14 +51,5 @@ public void Equals_EqualityOperators()
Assert.True(lb1 == lb2);
Assert.False(lb1 != lb2);
}

[Fact]
public void Equals_IEquatable()
{
IEquatable<Label> label1 = new Label();
Label label2 = new Label();

Assert.True(label1.Equals(label2));
}
}
}