fix: do not disconnect peers in TestWakuMetadataRequest (#826)

This commit is contained in:
richΛrd 2023-10-24 16:01:11 -04:00 committed by GitHub
parent 3d69e78cf3
commit 077df2fbb6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -54,6 +54,11 @@ func TestWakuMetadataRequest(t *testing.T) {
m16_2 := createWakuMetadata(t, &rs16_2)
m_noRS := createWakuMetadata(t, nil)
// Removing notifee to test metadata protocol functionality without having the peers being disconnected by the notify process
m16_1.h.Network().StopNotify(m16_1)
m16_2.h.Network().StopNotify(m16_2)
m_noRS.h.Network().StopNotify(m_noRS)
m16_1.h.Peerstore().AddAddrs(m16_2.h.ID(), m16_2.h.Network().ListenAddresses(), peerstore.PermanentAddrTTL)
m16_1.h.Peerstore().AddAddrs(m_noRS.h.ID(), m_noRS.h.Network().ListenAddresses(), peerstore.PermanentAddrTTL)