Skip to content

Add unit tests for integration, protocol factory, and remaining modules #968

@kcenon

Description

@kcenon

What

Add dedicated unit tests for 13 untested modules: integration bridges (5), protocol factories (4), remaining QUIC (2), HTTP/2 (1), and internal (1). Part of #953.

Scope

Category Count Files
Integration 5 container_integration, io_context_thread_manager, logger_integration, monitoring_integration, thread_integration
Protocol Factories 4 quic.cpp, tcp.cpp, udp.cpp, websocket.cpp (in src/protocol/)
QUIC remaining 2 connection_id_manager.cpp, stream_manager.cpp
HTTP/2 remaining 1 http2_server_stream.cpp
Internal 1 websocket_socket.cpp

Why

  • Integration modules bridge network_system with external systems (container, logger, monitoring) — untested bridges risk silent failures
  • Protocol factory functions are the primary entry points for creating protocol instances
  • QUIC connection_id_manager and stream_manager are critical protocol components
  • Part of epic Expand unit test coverage from 40% to 80% #953 to raise coverage from 48% to 80%

Where

  • Source: src/integration/, src/protocol/, src/protocols/quic/, src/protocols/http2/, 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
  2. Protocol factory tests: verify correct protocol instance creation and configuration
  3. QUIC tests: test connection ID management and stream lifecycle
  4. Integration tests: mock external system interfaces where needed

Acceptance Criteria

  • All 13 modules have dedicated unit test files
  • Tests pass on local build
  • 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