Skip to content

Conversation

@sanity
Copy link
Collaborator

@sanity sanity commented Nov 25, 2025

Problem

The six-peer connection-cap test depends on freenet-test-network, which makes the default cargo test pull in an external dev dependency. We want to avoid that dependency in the main test suite while still running the six-peer regression in CI.

Solution

  • Added an optional test-network feature that gates the freenet-test-network dev dependency.
  • Gated all freenet-test-network-based integration tests with #![cfg(feature = "test-network")] so they are excluded from the default cargo test run.
  • Added a dedicated CI job six_peer_connection_cap that runs the six-peer connection-cap test with --features trace,websocket,redb,test-network, keeping coverage in CI without affecting local cargo test.

Testing

  • cargo test -p freenet --test connection_cap --no-default-features --features trace,websocket,redb,test-network -- --list
  • cargo test -p freenet --no-default-features --features trace,websocket,redb -- --list

Notes

The six-peer test still runs in CI via the new job. Locally, run it explicitly with cargo test -p freenet --test connection_cap --no-default-features --features trace,websocket,redb,test-network -- --exact connection_cap_respected --nocapture.

@iduartgomez iduartgomez added this pull request to the merge queue Nov 25, 2025
Merged via the queue into main with commit bf72b2e Nov 25, 2025
13 checks passed
@iduartgomez iduartgomez deleted the fix/six-peer-ci branch November 25, 2025 09:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants