diff options
author | Péter Szilágyi <peterke@gmail.com> | 2015-04-14 20:16:02 +0800 |
---|---|---|
committer | Péter Szilágyi <peterke@gmail.com> | 2015-04-14 20:16:02 +0800 |
commit | f6efdd8aad96db24f29268b4393e95644dbbd18a (patch) | |
tree | 74d85a83763f5e20f3f036e9b7ca19711be5770d /whisper/whisper_test.go | |
parent | 1a4cfc173eb3f62c5859d25744f3c0de119e1b59 (diff) | |
download | go-tangerine-f6efdd8aad96db24f29268b4393e95644dbbd18a.tar go-tangerine-f6efdd8aad96db24f29268b4393e95644dbbd18a.tar.gz go-tangerine-f6efdd8aad96db24f29268b4393e95644dbbd18a.tar.bz2 go-tangerine-f6efdd8aad96db24f29268b4393e95644dbbd18a.tar.lz go-tangerine-f6efdd8aad96db24f29268b4393e95644dbbd18a.tar.xz go-tangerine-f6efdd8aad96db24f29268b4393e95644dbbd18a.tar.zst go-tangerine-f6efdd8aad96db24f29268b4393e95644dbbd18a.zip |
whisper: shorten constants to TTL and PoW
Diffstat (limited to 'whisper/whisper_test.go')
-rw-r--r-- | whisper/whisper_test.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/whisper/whisper_test.go b/whisper/whisper_test.go index 3f903a9dc..97644fd27 100644 --- a/whisper/whisper_test.go +++ b/whisper/whisper_test.go @@ -83,10 +83,10 @@ func TestSelfMessage(t *testing.T) { }) // Send a dummy message to oneself msg := NewMessage([]byte("self whisper")) - envelope, err := msg.Wrap(DefaultProofOfWork, Options{ + envelope, err := msg.Wrap(DefaultPoW, Options{ From: self, To: &self.PublicKey, - TTL: DefaultTimeToLive, + TTL: DefaultTTL, }) if err != nil { t.Fatalf("failed to wrap message: %v", err) @@ -126,10 +126,10 @@ func TestDirectMessage(t *testing.T) { }) // Send a dummy message from the sender msg := NewMessage([]byte("direct whisper")) - envelope, err := msg.Wrap(DefaultProofOfWork, Options{ + envelope, err := msg.Wrap(DefaultPoW, Options{ From: senderId, To: &recipientId.PublicKey, - TTL: DefaultTimeToLive, + TTL: DefaultTTL, }) if err != nil { t.Fatalf("failed to wrap message: %v", err) @@ -184,9 +184,9 @@ func testBroadcast(anonymous bool, t *testing.T) { } // Send a dummy message from the sender msg := NewMessage([]byte("broadcast whisper")) - envelope, err := msg.Wrap(DefaultProofOfWork, Options{ + envelope, err := msg.Wrap(DefaultPoW, Options{ Topics: NewTopicsFromStrings("broadcast topic"), - TTL: DefaultTimeToLive, + TTL: DefaultTTL, }) if err != nil { t.Fatalf("failed to wrap message: %v", err) |