LCTIO Testing
Use this skill for test additions, fixture design, and coverage-oriented validation.
Pytest Conventions
- Test files:
test_*.py - Test classes:
Test* - Test functions:
test_* - Prefer
tmp_pathfor filesystem tests.
Commands
python -m pytestpytest --cov=lctio --cov-report=termpytest --cov=lctio --cov-report=term --cov-report=xml:reports/junit/coverage.xml --junit-xml=reports/junit/pytest.xml
Expectations
- New behavior should ship with direct tests.
- Use coverage output to identify untested code paths when a change is non-trivial.
- Keep tests deterministic; prefer seeded random data for generated image fixtures.
TIFF-Specific Guidance
For compressed TIFF fixtures and dtype edge cases, read references/tiff-fixtures.md.