From 55e40f45368bdd838e825fce441c013d2963d521 Mon Sep 17 00:00:00 2001 From: Olaoluwa Osuntokun Date: Wed, 9 Nov 2022 12:47:05 -0800 Subject: [PATCH] btcec/schnorr/musig2: fix BenchmarkPartialVerify In this commit, we fix the `BenchmarkPartialVerify` test. When we moved to musig 1.0, we stopped requiring the input as an x-only key. So we need to remove the round trip serialization to force the key to be x-only. --- btcec/schnorr/musig2/bench_test.go | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/btcec/schnorr/musig2/bench_test.go b/btcec/schnorr/musig2/bench_test.go index 751ee737..aac298aa 100644 --- a/btcec/schnorr/musig2/bench_test.go +++ b/btcec/schnorr/musig2/bench_test.go @@ -45,12 +45,7 @@ func genSigner(t *testing.B) signer { t.Fatalf("unable to gen priv key: %v", err) } - pubKey, err := schnorr.ParsePubKey( - schnorr.SerializePubKey(privKey.PubKey()), - ) - if err != nil { - t.Fatalf("unable to gen key: %v", err) - } + pubKey := privKey.PubKey() nonces, err := GenNonces(WithPublicKey(pubKey)) if err != nil {