NUnit TestCase with Generics
NUnit test methods actually can be generic as long as the generic type arguments can be inferred from parameters: [TestCase(42)] [TestCase(“string”)] [TestCase(double.Epsilon)] public void GenericTest<T>(T instance) { Console.WriteLine(instance); } If the generic arguments cannot be inferred, the test runner will not have a clue how to resolve type arguments: [TestCase(42)] [TestCase(“string”)] [TestCase(double.Epsilon)] public void GenericTest<T>(object … Read more