-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement claiming after unbonding period
- Loading branch information
1 parent
02db1dc
commit 680aa2f
Showing
12 changed files
with
1,004 additions
and
189 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// SPDX-License-Identifier: MIT OR Apache-2.0 | ||
pragma solidity ^0.8.26; | ||
|
||
import {Script} from "forge-std/Script.sol"; | ||
import {DelegationV2} from "src/DelegationV2.sol"; | ||
import "forge-std/console.sol"; | ||
|
||
contract Claim is Script { | ||
function run(address payable proxy) external { | ||
|
||
address staker = msg.sender; | ||
|
||
DelegationV2 delegation = DelegationV2( | ||
proxy | ||
); | ||
|
||
console.log("Running version: %s", | ||
delegation.version() | ||
); | ||
|
||
console.log("Staker balance before: %s ZIL", | ||
staker.balance | ||
); | ||
|
||
vm.broadcast(); | ||
|
||
delegation.claim(); | ||
|
||
console.log("Staker balance after: %s ZIL", | ||
staker.balance | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.