Search in sources :

Example 1 with PeersView

use of com.radixdlt.network.p2p.PeersView in project radixdlt by radixdlt.

the class PeerLivenessMonitorTest method setup.

@Before
public void setup() throws ParseException {
    this.p2PConfig = P2PConfig.fromRuntimeProperties(new RuntimeProperties(new JSONObject(), new String[] {}));
    this.peersView = mock(PeersView.class);
    this.peerEventDispatcher = rmock(EventDispatcher.class);
    this.pingEventDispatcher = rmock(RemoteEventDispatcher.class);
    this.pongEventDispatcher = rmock(RemoteEventDispatcher.class);
    this.pingTimeoutEventDispatcher = rmock(ScheduledEventDispatcher.class);
    this.sut = new PeerLivenessMonitor(p2PConfig, peersView, peerEventDispatcher, pingEventDispatcher, pongEventDispatcher, pingTimeoutEventDispatcher);
}
Also used : PeersView(com.radixdlt.network.p2p.PeersView) ScheduledEventDispatcher(com.radixdlt.environment.ScheduledEventDispatcher) RemoteEventDispatcher(com.radixdlt.environment.RemoteEventDispatcher) EventDispatcher(com.radixdlt.environment.EventDispatcher) JSONObject(org.json.JSONObject) RemoteEventDispatcher(com.radixdlt.environment.RemoteEventDispatcher) ScheduledEventDispatcher(com.radixdlt.environment.ScheduledEventDispatcher) RuntimeProperties(com.radixdlt.properties.RuntimeProperties) Before(org.junit.Before)

Aggregations

EventDispatcher (com.radixdlt.environment.EventDispatcher)1 RemoteEventDispatcher (com.radixdlt.environment.RemoteEventDispatcher)1 ScheduledEventDispatcher (com.radixdlt.environment.ScheduledEventDispatcher)1 PeersView (com.radixdlt.network.p2p.PeersView)1 RuntimeProperties (com.radixdlt.properties.RuntimeProperties)1 JSONObject (org.json.JSONObject)1 Before (org.junit.Before)1