Skip to content

Commit 0e7104e

Browse files
authored
Ease testing of local stubs by extending "MYPYPATH" (#130)
1 parent b499462 commit 0e7104e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pytest_mypy_plugins/item.py

+2
Original file line numberDiff line numberDiff line change
@@ -391,5 +391,7 @@ def _collect_mypy_path(self, rootdir: Optional[Path]) -> None:
391391
if mypy_path_key:
392392
mypy_path_parts.append(maybe_to_abspath(mypy_path_key, rootdir))
393393
mypy_path_parts.append(mypy_path_key)
394+
if rootdir:
395+
mypy_path_parts.append(str(rootdir))
394396

395397
self.environment_variables["MYPYPATH"] = ":".join(mypy_path_parts)

0 commit comments

Comments
 (0)