A Python tool to enforce dependencies, using modular architecture π Open source π Installable via pip π§ Able to be adopted incrementally - β‘ Implemented with no runtime impact βΎοΈ Interoperable with your existing systems π¦ Written in rust
Right now, if tach test determines that all tests can be skipped, the exit code from pytest is 5. This might mean that we should adjust the way the plugin operates (there may be a more native way to indicate tests should be skipped), adjust pytest's configuration, or maybe we need to diverge from pytest's behavior here and manually return zero in this case.
Example:
.venv/bin/tach test
============ Cached results found! ============
==================================================== test session starts =====================================================
platform linux -- Python 3.12.3, pytest-8.2.2, pluggy-1.5.0
rootdir: /home/evan/Programming/tach
configfile: pyproject.toml
plugins: mock-3.14.0
collected 85 items
[Tach] Skipped 10 test files (85 tests) since they were unaffected by current changes.
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_affected_modules.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_parsing.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_check.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_file_tree.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_module_tree.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_cli.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_changed_files.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_report.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_imports.py'
[Tach] > Skipped '/home/evan/Programming/tach/python/tests/test_cache.py'
=================================================== no tests ran in 0.28s ====================================================
============ END Cached results ============
make: *** [Makefile:41: test] Error 5
@tiluckdave I think one at a time is best, given you are already working on #169. I think I will tackle this one since it's been bugging me in my pre-commit hook.
Right now, if
tach test
determines that all tests can be skipped, the exit code from pytest is 5. This might mean that we should adjust the way the plugin operates (there may be a more native way to indicate tests should be skipped), adjust pytest's configuration, or maybe we need to diverge from pytest's behavior here and manually return zero in this case.Example: