openpgp: fix vet issue in tests
https://golang.org/cl/111416 made vet spot this new issue by recognizing the len() call as side-effect free: redundant or: md.IsSymmetricallyEncrypted || md.IsSymmetricallyEncrypted Change-Id: I8b72eedb458365a50e14d5eec35b972ee61efb1f Reviewed-on: https://go-review.googlesource.com/112255 Run-TryBot: Filippo Valsorda <filippo@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Andrew Bonventre <andybons@golang.org>
This commit is contained in:
Родитель
4ec37c66ab
Коммит
21052ae466
|
@ -124,7 +124,7 @@ func checkSignedMessage(t *testing.T, signedHex, expected string) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if !md.IsSigned || md.SignedByKeyId != 0xa34d7e18c20c31bb || md.SignedBy == nil || md.IsEncrypted || md.IsSymmetricallyEncrypted || len(md.EncryptedToKeyIds) != 0 || md.IsSymmetricallyEncrypted {
|
if !md.IsSigned || md.SignedByKeyId != 0xa34d7e18c20c31bb || md.SignedBy == nil || md.IsEncrypted || md.IsSymmetricallyEncrypted || len(md.EncryptedToKeyIds) != 0 || md.DecryptedWith != (Key{}) {
|
||||||
t.Errorf("bad MessageDetails: %#v", md)
|
t.Errorf("bad MessageDetails: %#v", md)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче