Summary
unpause() shifts start_time forward by the pause duration:
let delta = now.saturating_sub(config.paused_at);
config.start_time = config.start_time.saturating_add(delta);
There is no test verifying this shift produces correct vesting amounts. If the shift is wrong, paused time would count toward vesting which is incorrect.
Tasks
Labels: testing, forge-vesting
Summary
unpause()shiftsstart_timeforward by the pause duration:There is no test verifying this shift produces correct vesting amounts. If the shift is wrong, paused time would count toward vesting which is incorrect.
Tasks
cliff=0,duration=1000,total=10_000, att=0t=200, pause (should have2_000vested,8_000remaining)t=400, unpause (paused for 200s —start_timeshifts to200)t=600, assertvested = 10_000 * (600-200)/1000 = 4_000(200s active pre-pause + 200s active post-resume)claim()att=600and assert it returns4_000t=1200(equivalent to 1000 active seconds), assertfully_vested == trueLabels:
testing,forge-vesting