Skip to content

Commit ad390d7

Browse files
committed
small edits for review
1 parent 81ba71d commit ad390d7

File tree

5 files changed

+6
-10
lines changed

5 files changed

+6
-10
lines changed

pythonFiles/tests/unittestadapter/test_execution.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
import pytest
1010

11-
PYTHON_FILES = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
11+
PYTHON_FILES = pathlib.Path(__file__).parent.parent
1212

13-
sys.path.insert(0, PYTHON_FILES)
13+
sys.path.insert(0, os.fspath(PYTHON_FILES))
1414
from unittestadapter.execution import parse_execution_cli_args, run_tests
1515

1616
TEST_DATA_PATH = pathlib.Path(__file__).parent / ".data"

pythonFiles/unittestadapter/discovery.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717
from typing_extensions import Literal
1818

1919
# Add the path to pythonFiles to sys.path to find testing_tools.socket_manager.
20-
PYTHON_FILES = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
21-
sys.path.insert(0, PYTHON_FILES)
20+
PYTHON_FILES = pathlib.Path(__file__).parent.parent
21+
sys.path.insert(0, os.fspath(PYTHON_FILES))
2222

2323
from testing_tools import socket_manager
2424

pythonFiles/unittestadapter/execution.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@
1515

1616
directory_path = pathlib.Path(__file__).parent.parent / "lib" / "python"
1717
# Add the path to pythonFiles to sys.path to find testing_tools.socket_manager.
18-
PYTHON_FILES = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
18+
PYTHON_FILES = pathlib.Path(__file__).parent.parent
1919

20-
sys.path.insert(0, PYTHON_FILES)
20+
sys.path.insert(0, os.fspath(PYTHON_FILES))
2121
# Add the lib path to sys.path to find the typing_extensions module.
2222
sys.path.insert(0, os.path.join(PYTHON_FILES, "lib", "python"))
2323
from testing_tools import process_json_util, socket_manager

pythonFiles/vscode_pytest/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,6 @@ def pytest_report_teststatus(report, config):
173173
"success",
174174
collected_test if collected_test else None,
175175
)
176-
# collected_tests[report.nodeid] = item_result
177176

178177

179178
ERROR_MESSAGE_CONST = {

src/client/testing/testController/unittest/testDiscoveryAdapter.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ export class UnittestTestDiscoveryAdapter implements ITestDiscoveryAdapter {
2929
) {}
3030

3131
public async discoverTests(uri: Uri): Promise<DiscoveredTestPayload> {
32-
// const deferred = createDeferred<DiscoveredTestPayload>();
3332
const settings = this.configSettings.getSettings(uri);
3433
const { unittestArgs } = settings.testing;
3534

@@ -54,8 +53,6 @@ export class UnittestTestDiscoveryAdapter implements ITestDiscoveryAdapter {
5453
} finally {
5554
this.testServer.deleteUUID(uuid);
5655
disposable.dispose();
57-
// deferred.resolve();
58-
// confirm with testing that this gets called (it must clean this up)
5956
}
6057
// placeholder until after the rewrite is adopted
6158
// TODO: remove after adoption.

0 commit comments

Comments
 (0)