Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR adds new assertion methods IsEquatableTo and IsNotEquatableTo to the aweXpect assertion library for testing equality using the IEquatable<T> interface.
- Introduces two generic extension methods that leverage C#'s
IEquatable<T>interface for type-safe equality comparisons - Adds comprehensive test coverage for both positive and negative assertion scenarios
- Updates public API surface to include the new methods in both .NET Standard 2.0 and .NET 8.0 targets
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
Source/aweXpect/That/ThatGeneric.IsEquatableTo.cs |
Core implementation of the IsEquatableTo and IsNotEquatableTo extension methods with constraint logic |
Tests/aweXpect.Tests/ThatGeneric.IsEquatableTo.Tests.cs |
Test suite for IsEquatableTo method covering success/failure cases and negated scenarios |
Tests/aweXpect.Tests/ThatGeneric.IsNotEquatableTo.Tests.cs |
Test suite for IsNotEquatableTo method covering success/failure cases and negated scenarios |
Tests/aweXpect.Api.Tests/Expected/aweXpect_netstandard2.0.txt |
Updated API surface for .NET Standard 2.0 target |
Tests/aweXpect.Api.Tests/Expected/aweXpect_net8.0.txt |
Updated API surface for .NET 8.0 target |
b09a6ef to
b3510cf
Compare
|
🚀 Benchmark ResultsDetails
|
Test Results 4 files ±0 4 suites ±0 24s ⏱️ +5s Results for commit ab6f873. ± Comparison against base commit f6a6c87. This pull request removes 54 and adds 54 tests. Note that renamed tests count towards both. |
|
This is addressed in release v2.22.0. |



This PR adds new assertion methods
IsEquatableToandIsNotEquatableToto the aweXpect assertion library for testing equality using theIEquatable<T>interface.EqualsfromIEquatable<T>#617