Fix Contact Retry Failure to Restart #541

Merged
sarah merged 17 commits from post-stable-fixes into master 2024-01-02 23:18:00 +00:00
1 changed files with 2 additions and 0 deletions
Showing only changes of commit 6034b8f167 - Show all commits

View File

@ -63,6 +63,8 @@ func TestContactRetryQueue(t *testing.T) {
// Publish an unrelated event to trigger the Plugin to go through a queuing cycle
// If we didn't do this we would have to wait 30 seconds for a check-in
bus.Publish(event.NewEvent(event.PeerStateChange, map[event.Field]string{event.RemotePeer: "test2", event.ConnectionState: "Disconnected"}))
bus.Publish(event.NewEvent(event.QueuePeerRequest, map[event.Field]string{event.RemotePeer: testOnion, event.LastSeen: time.Now().Format(time.RFC3339Nano)}))
time.Sleep(time.Second)
pinf, _ = cr.connections.Load(testOnion)
if pinf.(*contact).state != 1 {