Ben Ha | Register for Da Nang Hackcamp 2025 #5
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
A. Vesting pallet
1. Unit test
2. Additional test case
Add additional test case for
force_remove_vesting_schedule
3. Simulation videos
Successful Vested Transfer And Claiming Vested Tokens
This simulation shows:
a standard vested_transfer works correctly, locks the funds, and creates a vesting schedule. It corresponds to
vested_transfer_works
intests.rs
.a recipient can claim tokens that have vested over time. It corresponds to
claim_works
intests.rs
.Video:
Vesting_.Create.vesting.schedule.and.claim.vesting.mp4
Invalid Vesting Schedule Parameters
This simulation ensures that a
vested_transfer
will fail if the schedule has a period or period count of zero. It corresponds tovested_transfer_fails_if_zero_period_or_count
intests.rs
.Video:
Vesting_.Error.when.provide.invalid.parameters.while.creating.vesting.schedules.mp4
Updating Vesting Schedules (Sudo)
This simulation shows that a privileged account (Root origin) can update the vesting schedules for any account. It corresponds to
update_vesting_schedules_works
intests.rs
.Video:
Vesting_.Update.vesting.schedules.mp4
Force remove vesting schedules
This simulation shows the logic when force remove vesting schedules. It corresponds to
force_remove_vesting_schedule_works
intests.rs
.Video:
Vesting_.Force.remove.vesting.schedules.mp4
Claiming with Multiple Schedules
This simulation shows the claim logic when an account has multiple, overlapping vesting schedules. It corresponds to
multiple_vesting_schedule_claim_works
intests.rs
.Video:
Vesting_.Claim.multiple.vesting.schedules.mp4