I am generating NUnit testcases based on the file names.
The directory looks like this:
Customer
CustomerTestCase1.xml
CustomerTestCase2.xml
Account
AccountTestCase1.xml
AccountTestCase2.xml
I am using TestCaseSource:
string[] list = Directory.GetFiles(path, "*", SearchOption.AllDirectories)
foreach (string file in list)
{
yield return new TestCaseData(file)
}
How do I introduce hierarchy into the generated testcases? I need them to be organized in groups according to folder structure, so I could tick "Account" and all the account testcases would be selected.