Versions in this module Expand all Collapse all v1 v1.8.2 Mar 5, 2018 Changes in this version + type Disconnect struct + Error error + Peer discover.NodeID + type Exchange struct + Expects []Expect + Label string + Timeout time.Duration + Triggers []Trigger + type Expect struct + Code uint64 + Msg interface{} + Peer discover.NodeID + Timeout time.Duration + type ProtocolSession struct + IDs []discover.NodeID + Server *p2p.Server + func (self *ProtocolSession) TestDisconnected(disconnects ...*Disconnect) error + func (self *ProtocolSession) TestExchanges(exchanges ...Exchange) error + type ProtocolTester struct + func NewProtocolTester(t *testing.T, id discover.NodeID, n int, ...) *ProtocolTester + func (self *ProtocolTester) Connect(selfID discover.NodeID, peers ...*adapters.NodeConfig) + func (self *ProtocolTester) Stop() error + type TestPeer interface + Drop func(error) + ID func() discover.NodeID + type TestPeerPool struct + func NewTestPeerPool() *TestPeerPool + func (self *TestPeerPool) Add(p TestPeer) + func (self *TestPeerPool) Get(id discover.NodeID) TestPeer + func (self *TestPeerPool) Has(id discover.NodeID) bool + func (self *TestPeerPool) Remove(p TestPeer) + type Trigger struct + Code uint64 + Msg interface{} + Peer discover.NodeID + Timeout time.Duration