morelinq / MoreLINQ

Extensions to LINQ to Objects
https://morelinq.github.io/
Apache License 2.0
3.63k stars 409 forks source link

Review NUnit1030 #1024

Open atifaziz opened 8 months ago

atifaziz commented 8 months ago

In PR #1023, updating the NUnit.Analyzers to version 3.8.0 introduced NUnit1030 warnings/errors:

A:\MoreLINQ\main\MoreLinq.Test\NullArgumentTest.cs(33,31,33,58): error NUnit1030: The TestCaseSource provides type 'NUnit.Framework.Interfaces.ITestCaseData', but the Test method expects type 'System.Action' for parameter 'testCase' (https://github.com/nunit/nunit.analyzers/tree/master/documentation/NUnit1030.md)
A:\MoreLINQ\main\MoreLinq.Test\NullArgumentTest.cs(37,31,37,60): error NUnit1030: The TestCaseSource provides type 'NUnit.Framework.Interfaces.ITestCaseData', but the Test method expects type 'System.Action' for parameter 'testCase' (https://github.com/nunit/nunit.analyzers/tree/master/documentation/NUnit1030.md)
A:\MoreLINQ\main\MoreLinq.Test\ReturnTest.cs(151,25,151,51): error NUnit1030: The TestCaseSource provides type 'NUnit.Framework.Interfaces.ITestCaseData', but the Test method expects type 'System.Action' for parameter 'unsupportedAction' (https://github.com/nunit/nunit.analyzers/tree/master/documentation/NUnit1030.md)

Since all tests pass regardless, the severity of NUnit1030 was demoted to suggestion:

https://github.com/morelinq/MoreLINQ/blob/91d3996df623934cf5a666bd34a4b039056aaa98/MoreLinq.Test/.editorconfig#L41-L42

It should be reviewed and ideally restored to a warning.