mirror of
https://github.com/go-micro/go-micro.git
synced 2025-08-04 21:42:57 +02:00
fix: some linting issues (#2563)
This commit is contained in:
@ -30,14 +30,14 @@ func TestBox(t *testing.T) {
|
||||
}
|
||||
aliceSecret := []byte("Why is a raven like a writing-desk?")
|
||||
if _, err := alice.Encrypt(aliceSecret); err == nil {
|
||||
t.Error("alice.Encrypt succeded without a public key")
|
||||
t.Error("alice.Encrypt succeeded without a public key")
|
||||
}
|
||||
enc, err := alice.Encrypt(aliceSecret, secrets.RecipientPublicKey(bob.Options().PublicKey))
|
||||
if err != nil {
|
||||
t.Error("alice.Encrypt failed")
|
||||
}
|
||||
if _, err := bob.Decrypt(enc); err == nil {
|
||||
t.Error("bob.Decrypt succeded without a public key")
|
||||
t.Error("bob.Decrypt succeeded without a public key")
|
||||
}
|
||||
if dec, err := bob.Decrypt(enc, secrets.SenderPublicKey(alice.Options().PublicKey)); err == nil {
|
||||
if !reflect.DeepEqual(dec, aliceSecret) {
|
||||
|
Reference in New Issue
Block a user