Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR refactors the ResultContexts class from using a custom linked-list implementation to using a standard List<ResultContext>. This simplification removes the internal _next field from ResultContext and replaces manual linked-list operations with built-in list methods. The changes also update test expectations to reflect improved error message formatting that now includes both "Actual" and "Expected" sections.
Key Changes
- Replaced custom linked-list implementation in
ResultContextswithList<ResultContext> - Removed internal
_nextfield fromResultContextclass - Added test case to verify the same context can be added multiple times
Reviewed Changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| Source/aweXpect.Core/Core/ResultContexts.cs | Replaces linked-list implementation with List<ResultContext> for simpler collection management |
| Source/aweXpect.Core/Core/ResultContext.cs | Removes internal _next field no longer needed after linked-list removal |
| Tests/aweXpect.Core.Tests/Core/ResultContextsTests.cs | Adds test for adding same context multiple times to verify list-based implementation |
| Tests/aweXpect.Core.Tests/Options/StringEqualityOptionsTests.WildcardMatchTypeTests.cs | Updates test expectations to include "Expected" section in error messages |
| Tests/aweXpect.Core.Tests/Options/StringEqualityOptionsTests.RegexMatchTypeTests.cs | Updates test expectations to include "Expected" section in error messages |
| Tests/aweXpect.Core.Tests/Options/StringEqualityOptionsTests.ExactMatchTypeTests.cs | Updates test expectations to include "Expected" section in error messages |
| Tests/aweXpect.Core.Tests/Customization/CustomizeFormattingTests.cs | Updates test expectations to include "Expected" section in error messages |
| Tests/aweXpect.Core.Tests/Core/Nodes/WhichNodeTests.cs | Updates test expectations to include "Expected" section in error messages |
|
🚀 Benchmark ResultsDetails
|
Test Results 4 files - 37 4 suites - 37 24s ⏱️ - 3m 20s Results for commit 1c8d7ff. ± Comparison against base commit 52008dd. This pull request removes 16839 and adds 52 tests. Note that renamed tests count towards both. |
👽 Mutation ResultsaweXpectDetails
The final mutation score is NaN%Coverage Thresholds: high:80 low:60 break:0aweXpect.CoreDetails
The final mutation score is 92.31%Coverage Thresholds: high:80 low:60 break:0 |



This PR refactors the
ResultContextsclass from using a custom linked-list implementation to using a standardList<ResultContext>. This simplification removes the internal_nextfield fromResultContextand replaces manual linked-list operations with built-in list methods. The changes also update test expectations to reflect improved error message formatting that now includes both "Actual" and "Expected" sections.Key Changes
ResultContextswithList<ResultContext>_nextfield fromResultContextclass