You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
unittest-discover: Avoid adding test parent dir to sys.path.
When running tests from subfolders, import by "full dotted path" rather than just module name, removing the need to add the test parent folder to `sys.path`. This matches CPython more closely, which places `abspath(top)` at the start of `sys.path` but doesn't include the test file parent dir at all. It fixes issues where projects may include a `test_xxx.py` file in their distribution which would (prior to this change) be unintentionally found by unittest-discover. Signed-off-by: Andrew Leech <andrew.leech@planetinnovation.com.au>
0 commit comments