Skip to content

Commit

Permalink
Test: Fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
jbe2277 committed Jan 6, 2025
1 parent b4848d1 commit 9127daf
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,9 @@ public void ValidationResultComparerTest()
var comparerType = typeof(ValidatableModel).GetNestedType("ValidationResultComparer", BindingFlags.NonPublic)!;
var comparer = (IEqualityComparer<ValidationResult>)comparerType.GetProperty("Default", BindingFlags.Static | BindingFlags.Public)!.GetValue(null)!;

Assert.IsTrue(comparer.Equals(null, null));
Assert.IsFalse(comparer.Equals(new ValidationResult(null), null));
Assert.IsFalse(comparer.Equals(null, new ValidationResult(null)));
Assert.IsTrue(comparer.Equals(null!, null!));
Assert.IsFalse(comparer.Equals(new ValidationResult(null), null!));
Assert.IsFalse(comparer.Equals(null!, new ValidationResult(null)));
Assert.IsTrue(comparer.Equals(new ValidationResult(null), new ValidationResult(null)));
Assert.IsFalse(comparer.Equals(new ValidationResult("Test"), new ValidationResult("Bill")));
Assert.IsTrue(comparer.Equals(new ValidationResult("Test"), new ValidationResult("Test")));
Expand Down

0 comments on commit 9127daf

Please sign in to comment.