in src/test-info/test-info.ts [81:92]
setDisplayName(relativeToItem?: TestCaseInfo | undefined) {
if (relativeToItem?.type === TestItemType.TargetDirectory) {
// If the relative item is another TargetDirTestCaseInfo, calculate relative path.
this.testItem.label = path.relative(
(relativeToItem as TargetDirTestCaseInfo).dir,
this.dir
)
} else {
// If it is another type of test item, use the full path.
this.testItem.label = this.dir
}
}