Skip to content

Commit a5aa9f0

Browse files
committed
Improve error message for missing default FastAPI app file in tests
1 parent 3c098a6 commit a5aa9f0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tests/test_utils_default_dir.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,6 @@ def test_app_dir_non_default() -> None:
8383
with pytest.raises(FastAPICLIException) as e:
8484
get_import_string()
8585
assert (
86-
"Could not find a default file to run, please provide an explicit path"
86+
"Could not find a default FastAPI app file. Please ensure one of the following files exists"
8787
in e.value.args[0]
8888
)

tests/test_utils_default_file.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,6 @@ def test_non_default_file(capsys: CaptureFixture[str]) -> None:
9898
with pytest.raises(FastAPICLIException) as e:
9999
get_import_string()
100100
assert (
101-
"Could not find a default file to run, please provide an explicit path"
101+
"Could not find a default FastAPI app file. Please ensure one of the following files exists"
102102
in e.value.args[0]
103103
)

0 commit comments

Comments
 (0)