Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add host with circuitv2 to integration test #3162

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

badgooooor
Copy link
Contributor

Description

@badgooooor badgooooor marked this pull request as ready for review February 5, 2025 14:07
Comment on lines 871 to 874
func TestConnRelay(t *testing.T) {
for _, tc := range transportsToTest {
if tc.Name != RelayTestOnTransportName {
continue
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't want a separate test for Relay. We want to run all integration tests with a Relay transport.

This package has a bunch of tests that we want all transports to satisfy, like ConnGater Test, ResourceManager Test, PingPong on streams, etc. We should add another transport to the list of already present transports which connects hosts over a circuit relay address.

At the moment it's fine to ignore which underlying transport is used to make the relay connection, and just use QUIC as the underlying transport. Ideally, any problem in the underlying transports should be caught when testing that specifc transport.

Comment on lines 82 to 83
var transportsToTest = []TransportTestCase{
{
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add another item to this list with Name: "circuit-v2"

Comment on lines 168 to 170
if opts.EnabledRelay {
libp2pOpts = append(libp2pOpts, libp2p.EnableRelay(), libp2p.EnableRelayService())
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's better to just run the relay test separately. Where the dialer and the listener are both using p2p-circuit to connect.

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.

Add transport integration tests for circuitv2
2 participants