diff --git a/whisper/whisperv5/filter_test.go b/whisper/whisperv5/filter_test.go index 0b0b282a08..8c868c66a4 100644 --- a/whisper/whisperv5/filter_test.go +++ b/whisper/whisperv5/filter_test.go @@ -216,6 +216,14 @@ func TestInstallIdenticalFilters(t *testing.T) { t.Fatalf("failed matching with the first filter") } + if ! filter2.MatchEnvelope(env) { + t.Fatalf("failed matching with the first filter") + } + + if ! filter1.MatchMessage(msg) { + t.Fatalf("failed matching with the second filter") + } + if ! filter2.MatchMessage(msg) { t.Fatalf("failed matching with the second filter") } diff --git a/whisper/whisperv5/whisper_test.go b/whisper/whisperv5/whisper_test.go index 9957412e85..f18752c8c5 100644 --- a/whisper/whisperv5/whisper_test.go +++ b/whisper/whisperv5/whisper_test.go @@ -704,7 +704,7 @@ func TestSymmetricSendCycle(t *testing.T) { } // check w.messages() - time.Sleep(100 * time.Millisecond) + time.Sleep(5 * time.Millisecond) mail1 := filter1.Retrieve() mail2 := filter2.Retrieve() if len(mail2) == 0 { @@ -777,7 +777,7 @@ func TestSymmetricSendWithoutAKey(t *testing.T) { } // check w.messages() - time.Sleep(100 * time.Millisecond) + time.Sleep(5 * time.Millisecond) mail := filter.Retrieve() if len(mail) == 0 { t.Fatalf("did not receive message in spite of not setting a public key") @@ -843,7 +843,7 @@ func TestSymmetricSendKeyMismatch(t *testing.T) { } // check w.messages() - time.Sleep(100 * time.Millisecond) + time.Sleep(5 * time.Millisecond) mail := filter.Retrieve() if len(mail) > 0 { t.Fatalf("received a message when keys weren't matching")