Skip to content

Commit 34fd989

Browse files
committed
fix tests
1 parent a88f4eb commit 34fd989

File tree

4 files changed

+298
-188
lines changed

4 files changed

+298
-188
lines changed

codeflash/tracing/tracing_new_process.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def __init__(
6464
project_root: Path | None = None,
6565
max_function_count: int = 256,
6666
timeout: int | None = None, # seconds
67-
command: str | None = None,
67+
command: str = "",
6868
) -> None:
6969
"""Use this class to trace function calls.
7070

tests/test_test_runner.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ def test_sort():
9898
assert results[0].did_pass, "Test did not pass as expected"
9999
result_file.unlink(missing_ok=True)
100100

101-
code = """import torch
101+
code = """import torch_does_not_exist
102102
def sorter(arr):
103103
print(torch.ones(1))
104104
arr.sort()
@@ -143,5 +143,5 @@ def test_sort():
143143
test_xml_file_path=result_file, test_files=test_files, test_config=config, run_result=process
144144
)
145145
match = ImportErrorPattern.search(process.stdout).group()
146-
assert match == "ModuleNotFoundError: No module named 'torch'"
146+
assert match == "ModuleNotFoundError: No module named 'torch_does_not_exist'"
147147
result_file.unlink(missing_ok=True)

0 commit comments

Comments
 (0)