Skip to content

Commit

Permalink
add logging for when testing is already running and causes new runs t…
Browse files Browse the repository at this point in the history
…o be canceled (#22653)

This logging will provide greater visibility for users as the discovery
or execution process immediately exits since the process interprets
there is already a similar process is going. This can inform users or
help spot bugs
  • Loading branch information
eleanorjboyd authored Dec 15, 2023
1 parent a5ab3b8 commit a05dee8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/client/testing/testController/workspaceTestAdapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export class WorkspaceTestAdapter {
debugLauncher?: ITestDebugLauncher,
): Promise<void> {
if (this.executing) {
traceError('Test execution already in progress, not starting a new one.');
return this.executing.promise;
}

Expand Down Expand Up @@ -119,6 +120,7 @@ export class WorkspaceTestAdapter {

// Discovery is expensive. If it is already running, use the existing promise.
if (this.discovering) {
traceError('Test discovery already in progress, not starting a new one.');
return this.discovering.promise;
}

Expand Down

0 comments on commit a05dee8

Please sign in to comment.