Test runner should exclude __pycache__ directories
|Reported by:||clelland||Owned by:||nobody|
|Severity:||Normal||Keywords:||Testing Python3 pycache|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
Beginning with Python 3.2, the Python runtime now stores .pyc files in a subdirectory named __pycache__, rather than alongside their counterpart .py sources. These directories are created automatically any time that the code is imported in a Python3.2+ environment.
The test runner needs to explicitly ignore those directories when searching for tests, as it does with hidden files and directories, init.py files, and dirs named 'sql'. Currently, the full (auto-discovered) test suite will not run after tests have been run with Python 3.
This may have implications for other auto discovery mechanisms as well.
Change History (6)
Changed 5 years ago by clelland
comment:1 Changed 5 years ago by clelland
- Has patch set
- Needs documentation unset
- Needs tests unset
- Patch needs improvement unset