Skip to content

Add unit tests for remaining QUIC protocol modules #974

Description

@kcenon

What

Add dedicated unit tests for 5 remaining untested QUIC protocol modules. Part of #953.

Scope

Module Source Path Coverage
crypto src/protocols/quic/crypto.cpp None
connection src/protocols/quic/connection.cpp None
pmtud_controller src/protocols/quic/pmtud_controller.cpp None
quic_socket src/internal/quic_socket.cpp None
session_ticket_store src/protocols/quic/session_ticket_store.cpp None

Why

  • QUIC crypto and connection are foundational protocol components — untested code risks silent TLS/handshake failures
  • PMTUD (Path MTU Discovery) controller affects packet sizing on all QUIC connections
  • Part of epic Expand unit test coverage from 40% to 80% #953 to raise coverage from ~48% to 80%

Where

  • Source: src/protocols/quic/, src/internal/
  • Tests: tests/unit/ (new test files)
  • CMake: tests/CMakeLists.txt (register new tests)

How

Technical Approach

  1. Create unit test files following existing project patterns (see quic_*_test.cpp files)
  2. crypto: test key derivation, AEAD encryption/decryption, key update
  3. connection: test state machine transitions, handshake flow, packet processing
  4. pmtud_controller: test MTU probing, path validation, size selection
  5. quic_socket: test socket creation, binding, send/receive

Acceptance Criteria

  • All 5 modules have dedicated unit test files
  • Tests pass on local build and CI (Ubuntu, macOS)
  • No GTEST_SKIP() markers
  • Tests cover construction, public methods, and error paths

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions