-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #24 from blockful-io/test/integration
Test/integration
- Loading branch information
Showing
9 changed files
with
411 additions
and
46 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
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,7 @@ | ||
pragma solidity 0.8.26; | ||
|
||
address constant STAKING_TOKEN = 0xe485E2f1bab389C08721B291f6b59780feC83Fd7; // shutter token | ||
address constant CONTRACT_OWNER = 0x36bD3044ab68f600f6d3e081056F34f2a58432c4; // shuter multisig | ||
uint256 constant LOCK_PERIOD = 182 days; | ||
uint256 constant MIN_STAKE = 50_000e18; | ||
uint256 constant REWARD_RATE = 0.1333333333e18; |
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,42 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity 0.8.26; | ||
|
||
import "@forge-std/Script.sol"; | ||
import {TransparentUpgradeableProxy} from "@openzeppelin/contracts/proxy/transparent/TransparentUpgradeableProxy.sol"; | ||
import {RewardsDistributor} from "src/RewardsDistributor.sol"; | ||
import {Staking} from "src/Staking.sol"; | ||
import "./Constants.sol"; | ||
|
||
contract Deploy is Script { | ||
function run() | ||
public | ||
returns (Staking stakingProxy, RewardsDistributor rewardsDistributor) | ||
{ | ||
vm.startBroadcast(); | ||
|
||
rewardsDistributor = new RewardsDistributor( | ||
CONTRACT_OWNER, | ||
STAKING_TOKEN | ||
); | ||
|
||
stakingProxy = Staking( | ||
address( | ||
new TransparentUpgradeableProxy( | ||
address(new Staking()), | ||
address(CONTRACT_OWNER), | ||
"" | ||
) | ||
) | ||
); | ||
|
||
stakingProxy.initialize( | ||
CONTRACT_OWNER, | ||
STAKING_TOKEN, | ||
address(rewardsDistributor), | ||
LOCK_PERIOD, | ||
MIN_STAKE | ||
); | ||
|
||
vm.stopBroadcast(); | ||
} | ||
} |
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.