Problem
Zero integration tests exist. The full protocol flow (TCP connect → TLS → HTTP upgrade → Noise handshake → register → map stream) is never tested end-to-end. wire.rs only tests URL parsing.
Required
- Mock TLS server using rcgen (test cert generation) + rustls ServerConfig
- Mock implements: GET /key?v=71, POST /ts2021 upgrade, register RPC, map streaming
- Tests:
- connects_and_completes_noise_handshake
- register_returns_authorized_on_valid_preauth_key
- register_returns_needs_auth_when_no_key
- map_stream_applies_initial_full_response
- map_stream_handles_delta_updates
- map_stream_keepalive_does_not_modify_netmap
- disconnected_server_returns_wire_error
- malformed_http_response_returns_error
Location
crates/dictyon/tests/wire_integration.rs
Dependencies
Add rcgen to [dev-dependencies].
Problem
Zero integration tests exist. The full protocol flow (TCP connect → TLS → HTTP upgrade → Noise handshake → register → map stream) is never tested end-to-end. wire.rs only tests URL parsing.
Required
Location
crates/dictyon/tests/wire_integration.rsDependencies
Add
rcgento[dev-dependencies].