Skip to content

test(proto-signing): cover multisig LegacyAminoPubKey in decodePubkey - #1975

Open
gomesalexandre wants to merge 2 commits into
cosmos:mainfrom
gomesalexandre:test_decodepubkey_multisig
Open

gomesalexandre wants to merge 2 commits into
cosmos:mainfrom
gomesalexandre:test_decodepubkey_multisig

Conversation

@gomesalexandre

Copy link
Copy Markdown

closes #1344

what

decodePubkey's /cosmos.crypto.multisig.LegacyAminoPubKey branch had no test coverage - pubkey.spec.ts only exercised the secp256k1, ed25519, and unsupported-type cases.

how

Adds a decodePubkey case that builds a 2-of-2 multisig over the existing secp256k1 and ed25519 keys, encodes it with encodePubkey, and asserts decodePubkey reconstructs the original multisig pubkey. This exercises the LegacyAminoPubKey branch on both encode and decode.

receipts

$ cd packages/proto-signing && yarn test
  decodePubkey
    ...
    ✓ works for multisig threshold pubkeys
Executed 43 of 43 specs SUCCESS in 24 secs.

gomesalexandre and others added 2 commits August 16, 2026 20:52
ExecuteResult only exposed events, dropping the binary data a contract returns
via Response::set_data (cosmos#1648). Add a `data: readonly Uint8Array[]`
field decoded from the tx's MsgExecuteContractResponse msgResponses, one entry
per instruction in order. Empty for Cosmos SDK < 0.46, which does not expose
message responses. Verified the decode round-trips the data; extended the
execute and executeMultiple specs to assert one data entry per instruction.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
decodePubkey's /cosmos.crypto.multisig.LegacyAminoPubKey branch had no test
coverage. Add a case that builds a 2-of-2 multisig over the existing
secp256k1 and ed25519 keys, encodes it, and checks decodePubkey reconstructs
it, exercising the LegacyAminoPubKey branch on both encode and decode.

closes cosmos#1344
@greptile-apps

greptile-apps Bot commented Aug 17, 2026

Copy link
Copy Markdown

PR author is not in the allowed authors list.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add LegacyAminoPubKey test case to decodePubkey testing

1 participant