Fix a bunch of deepsource warnings (#11814)

This commit is contained in:
Patrice Vignola
2022-12-22 01:20:10 -08:00
committed by GitHub
parent 77a9dca9eb
commit 83f48350b2
73 changed files with 197 additions and 197 deletions

View File

@@ -103,7 +103,7 @@ func TestDerivedKeymanager_FetchValidatingPublicKeys(t *testing.T) {
for i := 0; i < numAccounts; i++ {
privKey, err := util.PrivateKeyFromSeedAndPath(derivedSeed, fmt.Sprintf(ValidatingKeyDerivationPathTemplate, i))
require.NoError(t, err)
pubKey := [fieldparams.BLSPubkeyLength]byte{}
var pubKey [fieldparams.BLSPubkeyLength]byte
copy(pubKey[:], privKey.PublicKey().Marshal())
wantedPubKeys[i] = pubKey
}
@@ -142,7 +142,7 @@ func TestDerivedKeymanager_FetchValidatingPrivateKeys(t *testing.T) {
for i := 0; i < numAccounts; i++ {
privKey, err := util.PrivateKeyFromSeedAndPath(derivedSeed, fmt.Sprintf(ValidatingKeyDerivationPathTemplate, i))
require.NoError(t, err)
privKeyBytes := [32]byte{}
var privKeyBytes [32]byte
copy(privKeyBytes[:], privKey.Marshal())
wantedPrivKeys[i] = privKeyBytes
}