-
Notifications
You must be signed in to change notification settings - Fork 0
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 muxer compliance test suite and refactor tests to not depend on libp2p-swarm
#27
Conversation
578e42e
to
859a3b9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me. Thanks @thomaseizinger.
Great to see the muxer tests used here.
I suggest waiting for @elenaf9's approval.
There was an intention to test TLS handshakes: you can't setup a connection if you dial with one PeerID and you get another in response. |
Fair enough. But to actually test this on the TLS level, we need to pass in the expected peer ID as part of creating the config: But we currently pass
The code will have to undergo some refactoring where we don't reuse the same config for all connections so we can pass the expected I'd suggest we do this as a follow-up. The current test only validates logic that is present in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the delay. Thanks @thomaseizinger!
The concurrent_connections_and_streams_async_std
test runs forever when I run it locally. Any idea why that could be the case @thomaseizinger?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @thomaseizinger!
Various muxer implementations struggle to fulfill this test. In practice, it doesn't matter much because we always run `multistream-select` on top of a newly negotiated stream so we never end up actually reading from a stream that we have never written to. Relevant discussion: kpp#27 (comment)
Description
The first part is likely to not be controversial.
Migrating away from
libp2p-swarm
avoids circular dependencies across our workspace.libp2p-quic
is a transport and I'd argue that if the implementation only depends onlibp2p-core
, we should also test it outside of aSwarm
context.For example, this brings up the question on what to do with the
wrong_peer_id
test. Previously, this was testing functionality that is inlibp2p-swarm
.Links to any relevant issues
Open Questions
Change checklist