testing: fix debug session tracking not working for n>1 test runs (#215476)

This commit is contained in:
Connor Peet 2024-06-13 14:02:51 -07:00 committed by GitHub
parent 4e30f3ee15
commit 3eeefd2273
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -441,11 +441,9 @@ export class ExtHostTesting extends Disposable implements ExtHostTestingShape {
public getMetadataForRun(run: vscode.TestRun) {
for (const tracker of this.runTracker.trackers) {
const taskId = tracker.getTaskIdForRun(run);
if (!taskId) {
return undefined;
if (taskId) {
return { taskId, runId: tracker.id };
}
return { taskId, runId: tracker.id };
}
return undefined;