ReSharper 2024.1 Help

Code inspection: NUnit. Test case source must be non-abstract and implement IEnumerable.

Category

NUnit

ID

NUnit.TestCaseSourceShouldImplementIEnumerable

EditorConfig

resharper_n_unit_test_case_source_should_implement_i_enumerable_highlighting

Default severity

Warning

Language

C#

Requires SWA

No

NUnit's TestCaseSource attribute is used to identify the source from which the argument(s) will be provided for a parameterized test. The class that provides test cases must have a default constructor and implement IEnumerable. If the test source class does not implement IEnumerable, ReSharper issues a warning.

Note that NUnit allows different ways of specifying test case sources. For more information, refer to the TestCaseSourceAttribute documentation.

Last modified: 11 February 2024