Skip to content

Fix test failures from xUnit-to-Shouldly migration - #6

Merged
damianh merged 2 commits into
mainfrom
fix-ci
Apr 14, 2026
Merged

damianh merged 2 commits into
mainfrom
fix-ci

Conversation

@damianh

@damianh damianh commented Apr 14, 2026

Copy link
Copy Markdown
Owner

Summary

  • Restore null-coalescing operators (?? []) on 45 assertions across 8 test files that were dropped during the xUnit v3 + Shouldly migration, causing 37 test failures
  • Replace self-closing XML tags with empty container elements in Ec2ServiceHandler.cs for consistency (e.g. <tagSet/> to <tagSet></tagSet>)

Root Cause

The Shouldly migration (commit a5f31d4) converted patterns like Assert.Empty(resp.Items ?? []) to resp.Items.ShouldBeEmpty(), dropping the null-coalescing that handled AWS SDK's XML deserialization behavior (empty/absent collection elements deserialize as null, not empty lists).

Test Files Fixed

File Fixes
Ec2Tests.cs 29 assertions
AlbTests.cs 4 assertions
SnsTests.cs 2 assertions
RdsTests.cs 2 assertions
IamTests.cs 2 assertions
SesTests.cs 2 assertions
S3Tests.cs 2 assertions
PersistenceTests.cs 2 assertions

All 1,178 tests pass, 0 failures.

@damianh
damianh merged commit 3619cf3 into main Apr 14, 2026
1 check passed
@damianh
damianh deleted the fix-ci branch April 22, 2026 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant