Skip to content

Commit 47a99ba

Browse files
committed
fix comments
1 parent cf31e81 commit 47a99ba

File tree

4 files changed

+6
-9
lines changed

4 files changed

+6
-9
lines changed

src/client/testing/testController/common/types.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import {
1212
Uri,
1313
WorkspaceFolder,
1414
} from 'vscode';
15-
// ** import { IPythonExecutionFactory } from '../../../common/process/types';
1615
import { TestDiscoveryOptions } from '../../common/types';
1716
import { IPythonExecutionFactory } from '../../../common/process/types';
1817

src/client/testing/testController/controller.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ export class PythonTestController implements ITestController, IExtensionSingleAc
389389
tool: 'pytest',
390390
debugging: request.profile?.kind === TestRunProfileKind.Debug,
391391
});
392-
// ** new execution runner/adapter
392+
// ** uncomment for NEW execution runner/adapter
393393
// const testAdapter =
394394
// this.testAdapters.get(workspace.uri) ||
395395
// (this.testAdapters.values().next().value as WorkspaceTestAdapter);
@@ -415,12 +415,11 @@ export class PythonTestController implements ITestController, IExtensionSingleAc
415415
);
416416
}
417417
if (settings.testing.unittestEnabled) {
418-
// potentially squeeze in the new execution way here?
419418
sendTelemetryEvent(EventName.UNITTEST_RUN, undefined, {
420419
tool: 'unittest',
421420
debugging: request.profile?.kind === TestRunProfileKind.Debug,
422421
});
423-
// new execution runner/adapter
422+
// uncomment for NEW execution runner/adapter
424423
// const testAdapter =
425424
// this.testAdapters.get(workspace.uri) ||
426425
// (this.testAdapters.values().next().value as WorkspaceTestAdapter);

src/client/testing/testController/pytest/pytestDiscoveryAdapter.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,15 @@ export class PytestTestDiscoveryAdapter implements ITestDiscoveryAdapter {
3737
}
3838
}
3939

40-
// ** Old version of discover tests.
4140
discoverTests(uri: Uri, executionFactory?: IPythonExecutionFactory): Promise<DiscoveredTestPayload> {
4241
if (executionFactory !== undefined) {
42+
// ** new version of discover tests.
4343
const settings = this.configSettings.getSettings(uri);
4444
const { pytestArgs } = settings.testing;
4545
traceVerbose(pytestArgs);
4646
return this.runPytestDiscovery(uri, executionFactory);
4747
}
48-
// if executionFactory is undefined, we are using the old version of discover tests.
48+
// if executionFactory is undefined, we are using the old method signature of discover tests.
4949
traceVerbose(uri);
5050
this.deferred = createDeferred<DiscoveredTestPayload>();
5151
return this.deferred.promise;

src/client/testing/testController/pytest/pytestExecutionAdapter.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ export class PytestTestExecutionAdapter implements ITestExecutionAdapter {
3939
}
4040
}
4141

42-
// ** Old version of discover tests.
4342
async runTests(
4443
uri: Uri,
4544
testIds: string[],
@@ -48,10 +47,10 @@ export class PytestTestExecutionAdapter implements ITestExecutionAdapter {
4847
): Promise<ExecutionTestPayload> {
4948
traceVerbose(uri, testIds, debugBool);
5049
if (executionFactory !== undefined) {
50+
// ** new version of run tests.
5151
return this.runTestsNew(uri, testIds, debugBool, executionFactory);
5252
}
53-
// TODO:Remove this line after enabling runs
54-
// if executionFactory is undefined, we are using the old version of discover tests.
53+
// if executionFactory is undefined, we are using the old method signature of run tests.
5554
this.outputChannel.appendLine('Running tests.');
5655
this.deferred = createDeferred<ExecutionTestPayload>();
5756
return this.deferred.promise;

0 commit comments

Comments
 (0)