Parent Issue: #4 Zero Test Coverage
Objective
Create comprehensive unit tests for the RiverLinkDataUpdateCoordinator covering data parsing, mode detection, and stream mapping.
Test Coverage Areas
Data Parsing Tests
Video Mode Detection Tests
Resolution Tests
Signal Extraction Tests
Error Scenarios
Mock Strategy
# Use fixture files for API responses
@pytest.fixture
def mock_api_response():
with open('tests/fixtures/api_responses.json') as f:
return json.load(f)
Target Coverage
- Goal: 85%+ line coverage for coordinator.py
- Focus: Parsing logic and edge cases
References
Priority
🔴 High - Critical parsing logic
Parent Issue: #4 Zero Test Coverage
Objective
Create comprehensive unit tests for the RiverLinkDataUpdateCoordinator covering data parsing, mode detection, and stream mapping.
Test Coverage Areas
Data Parsing Tests
Video Mode Detection Tests
Resolution Tests
Signal Extraction Tests
Error Scenarios
Mock Strategy
Target Coverage
References
custom_components/riverlink/coordinator.pyget-all-devices-actual-response.jsonPriority
🔴 High - Critical parsing logic