Author | SHA1 | Message | Date |
---|---|---|---|
Callum Waters |
c769e3e09b
|
p2p: track peer channels to avoid sending across a channel a peer doesn't have (#6601) | 3 years ago |
Sam Kleinman |
9ffa7e8a2b
|
types: move NodeInfo from p2p (#6618) | 3 years ago |
Sam Kleinman |
ae5f98881b
|
p2p: make NodeID and NetAddress public (#6583) | 3 years ago |
Sam Kleinman |
a855f96946
|
p2p: renames for reactors and routing layer internal moves (#6547) | 4 years ago |
Callum Waters |
64e7b5efea
|
p2p: add channel descriptors to open channel (#6440) | 4 years ago |
Erik Grinaker |
9b6d6a3ad0
|
p2p: tighten up Router and add tests (#6044)
This cleans up the `Router` code and adds a bunch of tests. These sorts of systems are a real pain to test, since they have a bunch of asynchronous goroutines living their own lives, so the test coverage is decent but not fantastic. Luckily we've been able to move all of the complex peer management and transport logic outside of the router, as synchronous components that are much easier to test, so the core router logic is fairly small and simple. This also provides some initial test tooling in `p2p/p2ptest` that automatically sets up in-memory networks and channels for use in integration tests. It also includes channel-oriented test asserters in `p2p/p2ptest/require.go`, but these have primarily been written for router testing and should probably be adapted or extended for reactor testing. |
4 years ago |