Add multisign helpers

This commit is contained in:
wltsmrz
2015-09-09 21:08:28 -07:00
parent a53249ccd7
commit 7e886b3260
8 changed files with 439 additions and 104 deletions

View File

@@ -2057,4 +2057,42 @@ describe('Remote', function() {
RegularKey: TX_JSON.Destination
});
});
it('Construct SignerListSet transaction', function() {
const tx = remote.createTransaction('SignerListSet', {
account: 'rsLEU1TPdCJPPysqhWYw9jD97xtG5WqSJm',
signerQuorum: 3,
signers: [
{
account: 'rH4KEcG9dEwGwpn6AyoWK9cZPLL4RLSmWW',
weight: 1
},
{
account: 'rPMh7Pi9ct699iZUTWaytJUoHcJ7cgyziK',
weight: 2
}
]
});
assert(tx instanceof Transaction);
assert.deepEqual(tx.tx_json, {
Flags: 0,
TransactionType: 'SignerListSet',
Account: 'rsLEU1TPdCJPPysqhWYw9jD97xtG5WqSJm',
SignerQuorum: 3,
SignerEntries: [
{
SignerEntry: {
Account: 'rH4KEcG9dEwGwpn6AyoWK9cZPLL4RLSmWW',
SignerWeight: 1
}
},
{
SignerEntry: {
Account: 'rPMh7Pi9ct699iZUTWaytJUoHcJ7cgyziK',
SignerWeight: 2
}
}
]
});
});
});