Hi All,
How can i get test case name during runtime in Visual Studio Test Framework?
I am using VS 2010 to write my unit test cases and I need to get test case name during Test Init for each test and save those in file.
Sample Code
[TestInitialize()]
public void MyTestInitialize()
{
string testCaseName = //Find way to get test case name of this test case
//Save Logic with TestCaseName
}
[TestMethod] public void T_1() { //Execute Test }
[TestMethod] public void T_2() { //Execute Test }