MadhuLambu
31 days agoContributor
Count number of test cases in Execution Plan
Hello Community,
I want to count the test items in the project's execution plan that are marked as test case and print their names. Any suggestion?
function CountTestCasesRecursive(testItem) {
let count = 0;
if (testItem.TestCase) { //there's no property called TestCase
count++;
}
for (let i = 0; i < testItem.ItemCount; i++) {
count += CountTestCasesRecursive(testItem.TestItem(i));
}
return count;
}