-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
patch: flow updates for RocketPoolRecipient + tests
- Loading branch information
1 parent
29912c4
commit dcfe798
Showing
18 changed files
with
1,336 additions
and
592 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRETH { | ||
function burn(uint256 _rethAmount) external; | ||
} | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRETH { | ||
function burn(uint256 _rethAmount) external; | ||
} |
22 changes: 11 additions & 11 deletions
22
src/interfaces/external/rocketPool/IRocketDepositPool.sol
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 |
---|---|---|
@@ -1,11 +1,11 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketDepositPool { | ||
function getBalance() external view returns (uint256); | ||
function getNodeBalance() external view returns (uint256); | ||
function getUserBalance() external view returns (int256); | ||
function getExcessBalance() external view returns (uint256); | ||
function deposit() external payable; | ||
function getMaximumDepositAmount() external view returns (uint256); | ||
} | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketDepositPool { | ||
function getBalance() external view returns (uint256); | ||
function getNodeBalance() external view returns (uint256); | ||
function getUserBalance() external view returns (int256); | ||
function getExcessBalance() external view returns (uint256); | ||
function deposit() external payable; | ||
function getMaximumDepositAmount() external view returns (uint256); | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketMinipoolBase { | ||
// IRocketMiniPoolDelegate | ||
function getEffectiveDelegate() external view returns (address); | ||
} |
50 changes: 50 additions & 0 deletions
50
src/interfaces/external/rocketPool/IRocketMinipoolDelegate.sol
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,50 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketMinipoolDelegate { | ||
function version() external view returns (uint8); | ||
function initialise(address _nodeAddress) external; | ||
function getFinalised() external view returns (bool); | ||
function getStatusBlock() external view returns (uint256); | ||
function getStatusTime() external view returns (uint256); | ||
function getScrubVoted(address _member) external view returns (bool); | ||
function getNodeAddress() external view returns (address); | ||
function getNodeFee() external view returns (uint256); | ||
function getNodeDepositBalance() external view returns (uint256); | ||
function getNodeRefundBalance() external view returns (uint256); | ||
function getNodeDepositAssigned() external view returns (bool); | ||
function getPreLaunchValue() external view returns (uint256); | ||
function getNodeTopUpValue() external view returns (uint256); | ||
function getVacant() external view returns (bool); | ||
function getPreMigrationBalance() external view returns (uint256); | ||
function getUserDistributed() external view returns (bool); | ||
function getUserDepositBalance() external view returns (uint256); | ||
function getUserDepositAssigned() external view returns (bool); | ||
function getUserDepositAssignedTime() external view returns (uint256); | ||
function getTotalScrubVotes() external view returns (uint256); | ||
function calculateNodeShare(uint256 _balance) external view returns (uint256); | ||
function calculateUserShare(uint256 _balance) external view returns (uint256); | ||
function preDeposit( | ||
uint256 _bondingValue, | ||
bytes calldata _validatorPubkey, | ||
bytes calldata _validatorSignature, | ||
bytes32 _depositDataRoot | ||
) external payable; | ||
function deposit() external payable; | ||
function userDeposit() external payable; | ||
function distributeBalance(bool _rewardsOnly) external; | ||
function beginUserDistribute() external; | ||
function userDistributeAllowed() external view returns (bool); | ||
function refund() external; | ||
function slash() external; | ||
function finalise() external; | ||
function canStake() external view returns (bool); | ||
function canPromote() external view returns (bool); | ||
function stake(bytes calldata _validatorSignature, bytes32 _depositDataRoot) external; | ||
function prepareVacancy(uint256 _bondAmount, uint256 _currentBalance) external; | ||
function promote() external; | ||
function dissolve() external; | ||
function close() external; | ||
function voteScrub() external; | ||
function reduceBondAmount() external; | ||
} |
30 changes: 15 additions & 15 deletions
30
src/interfaces/external/rocketPool/IRocketMinipoolQueue.sol
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 |
---|---|---|
@@ -1,15 +1,15 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketMinipoolQueue { | ||
function getTotalLength() external view returns (uint256); | ||
function getContainsLegacy() external view returns (bool); | ||
function getLength() external view returns (uint256); | ||
function getTotalCapacity() external view returns (uint256); | ||
function getEffectiveCapacity() external view returns (uint256); | ||
function getNextCapacityLegacy() external view returns (uint256); | ||
function enqueueMinipool(address _minipool) external; | ||
function dequeueMinipools(uint256 _maxToDequeue) external returns (address[] memory minipoolAddress); | ||
function getMinipoolAt(uint256 _index) external view returns(address); | ||
function getMinipoolPosition(address _minipool) external view returns (int256); | ||
} | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketMinipoolQueue { | ||
function getTotalLength() external view returns (uint256); | ||
function getContainsLegacy() external view returns (bool); | ||
function getLength() external view returns (uint256); | ||
function getTotalCapacity() external view returns (uint256); | ||
function getEffectiveCapacity() external view returns (uint256); | ||
function getNextCapacityLegacy() external view returns (uint256); | ||
function enqueueMinipool(address _minipool) external; | ||
function dequeueMinipools(uint256 _maxToDequeue) external returns (address[] memory minipoolAddress); | ||
function getMinipoolAt(uint256 _index) external view returns (address); | ||
function getMinipoolPosition(address _minipool) external view returns (int256); | ||
} |
22 changes: 11 additions & 11 deletions
22
src/interfaces/external/rocketPool/IRocketPoolMinipoolManager.sol
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 |
---|---|---|
@@ -1,11 +1,11 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketPoolMinipoolManager { | ||
function getMinipoolExists(address _minipoolAddress) external view returns (bool); | ||
function getMinipoolByPubkey(bytes memory _pubkey) external view returns (address); | ||
function getMinipoolWithdrawalCredentials(address _minipoolAddress) external pure returns (bytes memory); | ||
function getVacantMinipoolCount() external view returns (uint256); | ||
function getVacantMinipoolAt(uint256 _index) external view returns (address); | ||
function setMinipoolPubkey(bytes calldata _pubkey) external; | ||
} | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketPoolMinipoolManager { | ||
function getMinipoolExists(address _minipoolAddress) external view returns (bool); | ||
function getMinipoolByPubkey(bytes memory _pubkey) external view returns (address); | ||
function getMinipoolWithdrawalCredentials(address _minipoolAddress) external pure returns (bytes memory); | ||
function getVacantMinipoolCount() external view returns (uint256); | ||
function getVacantMinipoolAt(uint256 _index) external view returns (address); | ||
function setMinipoolPubkey(bytes calldata _pubkey) external; | ||
} |
24 changes: 12 additions & 12 deletions
24
src/interfaces/external/rocketPool/IRocketPoolStorage.sol
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 |
---|---|---|
@@ -1,12 +1,12 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketPoolStorage { | ||
function getAddress(bytes32 _key) external view returns (address r); | ||
function getUint(bytes32 _key) external view returns (uint256 r); | ||
function getString(bytes32 _key) external view returns (string memory); | ||
function getBytes(bytes32 _key) external view returns (bytes memory); | ||
function getBool(bytes32 _key) external view returns (bool r); | ||
function getInt(bytes32 _key) external view returns (int r); | ||
function getBytes32(bytes32 _key) external view returns (bytes32 r); | ||
} | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.19; | ||
|
||
interface IRocketPoolStorage { | ||
function getAddress(bytes32 _key) external view returns (address r); | ||
function getUint(bytes32 _key) external view returns (uint256 r); | ||
function getString(bytes32 _key) external view returns (string memory); | ||
function getBytes(bytes32 _key) external view returns (bytes memory); | ||
function getBool(bytes32 _key) external view returns (bool r); | ||
function getInt(bytes32 _key) external view returns (int256 r); | ||
function getBytes32(bytes32 _key) external view returns (bytes32 r); | ||
} |
Oops, something went wrong.