diff --git a/pytest.ini b/pytest.ini new file mode 100644 index 00000000..cec3f90c --- /dev/null +++ b/pytest.ini @@ -0,0 +1,69 @@ +[pytest] +# Pytest configuration for Fenrir screen reader + +# Test discovery patterns +python_files = test_*.py *_test.py +python_classes = Test* +python_functions = test_* + +# Test paths +testpaths = tests + +# Minimum Python version +minversion = 3.7 + +# Output options +addopts = + # Verbose output with test names + -v + # Show extra test summary info + -ra + # Enable strict markers (only registered markers allowed) + --strict-markers + # Show local variables in tracebacks + --showlocals + # Warnings configuration + -W ignore::DeprecationWarning + # Optional plugins (uncomment if installed): + # --timeout=30 # Requires pytest-timeout + # --cov-report=term-missing # Requires pytest-cov + # -x # Stop on first failure + +# Register custom markers +markers = + unit: Unit tests (fast, no mocking) + integration: Integration tests (require mocking) + driver: Driver tests (require root access) + slow: Tests that take more than 1 second + remote: Tests for remote control functionality + settings: Tests for settings and configuration + commands: Tests for command system + vmenu: Tests for VMenu system + +# Coverage configuration +[coverage:run] +source = src/fenrirscreenreader +omit = + */tests/* + */vmenu-profiles/* + */__pycache__/* + */site-packages/* + +[coverage:report] +# Fail if coverage falls below this percentage +# fail_under = 70 +exclude_lines = + # Standard pragma + pragma: no cover + # Don't complain about missing debug code + def __repr__ + # Don't complain if tests don't hit defensive assertion code + raise AssertionError + raise NotImplementedError + # Don't complain about abstract methods + @abstractmethod + # Don't complain about initialization + if __name__ == .__main__.: + +[coverage:html] +directory = htmlcov