-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathpytest.ini
More file actions
85 lines (75 loc) · 2.19 KB
/
pytest.ini
File metadata and controls
85 lines (75 loc) · 2.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
[pytest]
# Pytest configuration for madengine
# Test discovery
python_files = test_*.py
python_classes = Test*
python_functions = test_*
testpaths = tests/unit tests/integration tests/e2e
# Output and reporting
addopts =
# Verbose output
-v
# Show local variables in tracebacks
--tb=short
# Show summary of all test outcomes
-ra
# Strict markers (fail on unknown markers)
--strict-markers
# Show warnings
-W default
# Coverage (if pytest-cov is installed)
# --cov=src/madengine
# --cov-report=term-missing
# --cov-report=html
# Markers for test categorization
markers =
unit: Fast unit tests (no external dependencies)
integration: Integration tests (may be slower, test multiple components)
e2e: End-to-end tests (require full environment, Docker, may be very slow)
slow: Slow tests (can be skipped with -m "not slow")
gpu: Tests that require GPU hardware
amd: Tests specific to AMD GPUs
nvidia: Tests specific to NVIDIA GPUs
cpu: Tests for CPU-only execution
requires_docker: Tests that require Docker daemon
requires_models: Tests that require model fixtures
# Test execution
# Skip slow tests by default (run with --runslow to include them)
# To run only unit tests: pytest -m unit
# To run integration tests: pytest -m integration
# To exclude GPU tests: pytest -m "not gpu"
# To run AMD-specific tests: pytest -m amd
# Logging
log_cli = false
log_cli_level = INFO
log_cli_format = %(asctime)s [%(levelname)8s] %(message)s
log_cli_date_format = %Y-%m-%d %H:%M:%S
# Test timeouts (requires pytest-timeout)
# timeout = 300
# timeout_method = thread
# Warnings
filterwarnings =
# Treat warnings as errors (strict mode)
# error
# Ignore specific warnings
ignore::DeprecationWarning
ignore::PendingDeprecationWarning
# Minimum Python version
minversion = 3.8
# Coverage options (requires pytest-cov)
[coverage:run]
source = src/madengine
omit =
*/tests/*
*/test_*.py
*/__pycache__/*
*/site-packages/*
[coverage:report]
exclude_lines =
pragma: no cover
def __repr__
raise AssertionError
raise NotImplementedError
if __name__ == .__main__.:
if TYPE_CHECKING:
@abstractmethod