difftreelog
refactor(test app promo) fix comment
in: master
1 file changed
js-packages/tests/sub/appPromotion/appPromotion.test.tsdiffbeforeafterboth983function calculateIncome(base: bigint, iter = 0, calcPeriod: bigint = UNLOCKING_PERIOD): bigint {983function calculateIncome(base: bigint, iter = 0, calcPeriod: bigint = UNLOCKING_PERIOD): bigint {984 const DAY = 7200n;984 const DAY = 7200n;985 const ACCURACY = 1_000_000_000n;985 const ACCURACY = 1_000_000_000n;986 // 5n / 10_000n = 0.05% p/day986 // 453_256n / 1_000_000_000n = 0.0453256% /day987 const income = base + base * (ACCURACY * (calcPeriod * 453_256n) / (1_000_000_000n * DAY)) / ACCURACY ;987 const income = base + base * (ACCURACY * (calcPeriod * 453_256n) / (1_000_000_000n * DAY)) / ACCURACY ;988988989 if(iter > 1) {989 if(iter > 1) {