We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6b07654 commit c7f1ac4Copy full SHA for c7f1ac4
extensions/positron-python/python_files/unittestadapter/execution.py
@@ -171,6 +171,11 @@ def run_tests(
171
locals: Optional[bool] = None,
172
) -> PayloadDict:
173
cwd = os.path.abspath(start_dir)
174
+ if "/" in start_dir: # is a subdir
175
+ parent_dir = os.path.dirname(start_dir)
176
+ sys.path.insert(0, parent_dir)
177
+ else:
178
+ sys.path.insert(0, cwd)
179
status = TestExecutionStatus.error
180
error = None
181
payload: PayloadDict = {"cwd": cwd, "status": status, "result": None}
0 commit comments