-
-
Notifications
You must be signed in to change notification settings - Fork 110
fix: pass empty array to params parameter when [Arguments] has no values #4572
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
When [Arguments] is used with no arguments and the test method has a params parameter, the parameter now correctly receives an empty array instead of null. This matches standard C# behavior where calling a method with params and no arguments passes an empty array. Fixes #4561 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
SummaryFixes bug where Critical IssuesNone found ✅ AnalysisChanges Review:
This aligns with standard C# behavior where calling a method with a Test Coverage: TUnit Rules Compliance:
Correctness: Verdict✅ APPROVE - No critical issues |
Summary
[Arguments]with no values passednullinstead of an empty array toparamsparametersArgumentsAttributeconstructor now distinguishes between empty arguments ([]) and explicit null ([null])Fixes #4561
Test plan
ParamsOnlyWithEmptyArgumentspasses with 4 test casesParamsArgumentsTestspass🤖 Generated with Claude Code