-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Goal
Create a comprehensive test suite for the Python SDK covering unit tests (parsing, error mapping, state machine) and integration tests (end-to-end workflows against the local API), with >90% coverage.
Requirements
Functional
- Unit Tests (50+): Client initialization, retry logic, error mapping, state machine transitions, callback firing.
- Integration Tests (20+ scenarios): Full activation flow, heartbeat loop, grace mode, revocation, offline simulation.
- Fixtures: Mocked API responses, deterministic test data, offline simulation helpers.
- Coverage: >90% line coverage enforced in CI.
Technical
- Framework:
pytest+pytest-asyncio+respx(for mockinghttpx). - CI: Tests run in GitHub Actions on every push.
- Markers:
@pytest.mark.unitand@pytest.mark.integration.
Acceptance Criteria
- All unit tests pass without a running API.
- All integration tests pass against a local Docker Compose stack.
- Coverage report shows >90%.
- CI runs both suites on every push.
Dependencies
- Blocked by: Issue 23: Python SDK Core Client #23, Issue 24: SDK Heartbeat Loop and State Machine #24.
- Blocks: Issue 27: SDK Demo Application #27 (Demo App).
Reactions are currently unavailable