Skip to content

Gate the udp-server test environment behind a testing feature (#2482 subissue 4) #2699

Closed

Description

@josecelano

Subissue 4 of sub-EPIC #2482 (Reorganize test support code shared between workspace packages), itself a sub-EPIC of EPIC #1669 (Overhaul: Packages). It applies rule A of the ADR docs/adrs/20261021190318_share_workspace_test_support_through_testing_features.md to udp-server, the first server test environment to move.

Goal

Compile packages/udp-server/src/testing/ only with a non-default testing feature, make the one dependency only that module uses (torrust-tracker-swarm-coordination-registry) optional, and let the package's own targets (path-only self dev-dependency) and axum-health-check-api-server's [dev-dependencies] enable the feature.

Why

pub mod testing; is compiled unconditionally, so the test environment is part of the shipped public API and forces a dependency into normal builds.

Tasks

  • T1: record the baseline (dependency tree, test counts).
  • T2: gate the module, add the feature, the optional dependency, the self dev-dependency and the deny.toml wrapper entry.
  • T3: enable the feature from axum-health-check-api-server's [dev-dependencies].
  • T4: keep the existing example on the test environment, add a production-style example, and label both.
  • T5: verify (tests with and without --all-features, Shipped Features red and green, machete, deny, packaging, nightly check, bench build) and update the inventory and diagram.

The full specification is in the spec PR that follows.

Activity

  1. self-assigned this
    on Nov 3, 2026
  2. added 11 commits that reference this issue on Nov 3, 2026
  3. 7 remaining items

  4. added 8 commits that reference this issue on Nov 4, 2026
  5. added 5 commits that reference this issue on Nov 4, 2026
  6. added a commit that references this issue on Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions