HomePhabricator

[Cashtab] Equal airdrop distribution ratio option

Description

[Cashtab] Equal airdrop distribution ratio option

Summary:
As per T2687, this diff adds a toggle to the airdrop screen for the distribution ratio.
It's the pro-rata by default, and switching to equal will ensure all recipients will receive the same airdrop amount based on the 'Total XEC Airdrop' figure.

Test Plan:
npm test
npm start
test no regression to pro rata distribution
switch to equal ratio and test the recipient amounts are all equal and adds up to the 'Total XEC airdrop' amount
test ignore own address option in equal and prorata ratios
test ignore airdrops below min payment in equal and prorata ratios
test ignore etoken minter address in equal and prorata ratios
test ignore custom addresses in equal and prorata ratios
test with a 'Total XEC Airdrop' figure with a large decimal point (e.g. 100.333333333) and ensure each recipient amount is rounded to 2 decimal points

Reviewers: bytesofman, #bitcoin_abc

Reviewed By: bytesofman, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D12113

Details

Provenance
emackAuthored on Oct 1 2022, 09:43
emackPushed on Oct 7 2022, 11:30
Reviewer
Restricted Project
Differential Revision
D12113: [Cashtab] Equal airdrop distribution ratio option
Parents
rABC74bbb4ffb0f6: test: Remove intermittently failing and not very meaningful `BOOST_CHECK` in…
Branches
Unknown
Tags
Unknown