What
Expand unit test coverage for internal/quic_socket.cpp from current 43.7% line / 21.3% branch to >=70% line / >=50% branch.
Part of #953 .
Why
File is 439 LOC. New target identified in 2026-04-26 re-measurement.
Branch coverage at 21.3% means recovery and error-handling paths in QUIC socket abstraction are largely unverified.
v1.0 readiness gate requires >=80% line coverage ecosystem-wide (see Prepare network_system for v1.0 release #964 ).
Where
Source: internal/quic_socket.cpp (439 LOC)
Tests: tests/unit/internal/ (or new tests/unit/protocols/quic/quic_socket_test.cpp)
How
Approach
Audit existing quic_socket tests for uncovered branches.
Add tests for error paths: socket creation failure, bind failure, send/recv errors, MTU discovery edge cases.
Add tests for boundary cases: max packet sizes, stateless reset, datagram extension, ECN handling.
Add tests for OS-specific paths: macOS vs Linux vs Windows socket differences (where the file branches on platform).
Re-run coverage workflow to verify thresholds met.
Acceptance Criteria
What
Expand unit test coverage for
internal/quic_socket.cppfrom current 43.7% line / 21.3% branch to >=70% line / >=50% branch.Part of #953.
Why
Where
internal/quic_socket.cpp(439 LOC)tests/unit/internal/(or newtests/unit/protocols/quic/quic_socket_test.cpp)How
Approach
Acceptance Criteria
internal/quic_socket.cppline coverage >= 70%internal/quic_socket.cppbranch coverage >= 50%