feat: add API for decoding system instructions

This commit is contained in:
Justin Starry
2020-03-03 16:05:50 +08:00
committed by Michael Vines
parent 662ce22cdd
commit 6ed2bad9d0
12 changed files with 932 additions and 580 deletions

View File

@ -86,12 +86,12 @@ test('create and query nonce account', async () => {
},
]);
const transaction = SystemProgram.createNonceAccount(
from.publicKey,
nonceAccount.publicKey,
from.publicKey,
minimumAmount,
);
const transaction = SystemProgram.createNonceAccount({
fromPubkey: from.publicKey,
noncePubkey: nonceAccount.publicKey,
authorizedPubkey: from.publicKey,
lamports: minimumAmount,
});
await connection.sendTransaction(transaction, from, nonceAccount);
const expectedData = Buffer.alloc(68);