Skip to content

Commit bc8b857

Browse files
committed
build(pytest): set import mode to importlib
Use the importlib import mode for pytest to avoid issues with sys.path manipulation and improve reliability of test imports. This mode is recommended for projects with complex package structures.
1 parent 5f6ae09 commit bc8b857

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

template/pyproject.toml.jinja

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ extends = ".config/linters/pyrightconfig.json"
9191
addopts = [
9292
"--doctest-modules",
9393
"--hypothesis-show-statistics",
94+
"--import-mode=importlib",
9495
"--showlocals",
9596
"--strict-config",
9697
"--strict-markers",

0 commit comments

Comments
 (0)