a little bit more time to avoid races with restoring mutated config variables
This commit is contained in:
parent
37e1a81100
commit
a50deb04c0
|
@ -321,7 +321,7 @@ func TestGossipsubAttackGRAFTDuringBackoff(t *testing.T) {
|
|||
originalGossipSubPruneBackoffPenalty := GossipSubPruneBackoffPenalty
|
||||
GossipSubPruneBackoffPenalty = 500 * time.Millisecond
|
||||
defer func() {
|
||||
time.Sleep(time.Second)
|
||||
time.Sleep(time.Second + 100*time.Millisecond)
|
||||
GossipSubPruneBackoff = originalGossipSubPruneBackoff
|
||||
GossipSubPruneBackoffPenalty = originalGossipSubPruneBackoffPenalty
|
||||
GossipSubGraftFloodThreshold = originalGossipSubGraftFloodThreshold
|
||||
|
|
|
@ -272,7 +272,7 @@ func TestGossipsubFanoutMaintenance(t *testing.T) {
|
|||
func TestGossipsubFanoutExpiry(t *testing.T) {
|
||||
GossipSubFanoutTTL = 1 * time.Second
|
||||
defer func() {
|
||||
time.Sleep(time.Second)
|
||||
time.Sleep(time.Second + 100*time.Millisecond)
|
||||
GossipSubFanoutTTL = 60 * time.Second
|
||||
}()
|
||||
|
||||
|
@ -1000,7 +1000,7 @@ func TestGossipsubDirectPeers(t *testing.T) {
|
|||
originalGossipSubDirectConnectTicks := GossipSubDirectConnectTicks
|
||||
GossipSubDirectConnectTicks = 2
|
||||
defer func() {
|
||||
time.Sleep(time.Second)
|
||||
time.Sleep(time.Second + 100*time.Millisecond)
|
||||
GossipSubDirectConnectTicks = originalGossipSubDirectConnectTicks
|
||||
}()
|
||||
|
||||
|
@ -1286,7 +1286,7 @@ func TestGossipsubOpportunisticGrafting(t *testing.T) {
|
|||
originalGossipSubOpportunisticGraftTicks := GossipSubOpportunisticGraftTicks
|
||||
GossipSubOpportunisticGraftTicks = 2
|
||||
defer func() {
|
||||
time.Sleep(time.Second)
|
||||
time.Sleep(time.Second + 100*time.Millisecond)
|
||||
GossipSubPruneBackoff = originalGossipSubPruneBackoff
|
||||
GossipSubGraftFloodThreshold = originalGossipSubGraftFloodThreshold
|
||||
GossipSubOpportunisticGraftTicks = originalGossipSubOpportunisticGraftTicks
|
||||
|
|
Loading…
Reference in New Issue