generated from AngleProtocol/boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat do a test for setting the rate on the savings contract
- Loading branch information
1 parent
59656d4
commit 3af5b78
Showing
8 changed files
with
70 additions
and
165 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 was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,35 +1,19 @@ | ||
{ | ||
"calldatas": { | ||
"0": "0x01d5062a00000000000000000000000009d81464c7293c774203e46e3c921559c8e9d53f000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000015180000000000000000000000000000000000000000000000000000000000000002464d623530000000000000000000000000000000000000000000000000000000000093a8000000000000000000000000000000000000000000000000000000000", | ||
"1": "0xbb5a944f000000000000000000000000000000000000000000000000000000000000006e000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000003800000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000000000000000001000000000000000000000000169487a55de79476125a56b07c36ca8dbf37a3730000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000012401d5062a000000000000000000000000169487a55de79476125a56b07c36ca8dbf37a373000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000015180000000000000000000000000000000000000000000000000000000000000002464d623530000000000000000000000000000000000000000000000000000000000093a8000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000", | ||
"2": "0xbb5a944f000000000000000000000000000000000000000000000000000000000000006d000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000003800000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000c24766a56732b85eee5a383ed6614abd34fb6310000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000012401d5062a0000000000000000000000000c24766a56732b85eee5a383ed6614abd34fb631000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000015180000000000000000000000000000000000000000000000000000000000000002464d623530000000000000000000000000000000000000000000000000000000000093a8000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000", | ||
"3": "0xbb5a944f0000000000000000000000000000000000000000000000000000000000000091000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000003800000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000000000000000001000000000000000000000000b2ea590fcea142dcceaeb3912da4c1df721848ef0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000012401d5062a000000000000000000000000b2ea590fcea142dcceaeb3912da4c1df721848ef000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000015180000000000000000000000000000000000000000000000000000000000000002464d623530000000000000000000000000000000000000000000000000000000000093a8000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000", | ||
"4": "0xbb5a944f000000000000000000000000000000000000000000000000000000000000006a000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000003800000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000000010000000000000000000000007f27082eabdddc9dc3cc6632c9f594d210b9d43c0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000012401d5062a0000000000000000000000007f27082eabdddc9dc3cc6632c9f594d210b9d43c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000015180000000000000000000000000000000000000000000000000000000000000002464d623530000000000000000000000000000000000000000000000000000000000093a8000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000", | ||
"5": "0xbb5a944f00000000000000000000000000000000000000000000000000000000000000b8000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000003800000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000000000000000001000000000000000000000000f868da244c17cf0e288ae4a92c8636f072a7bae30000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000012401d5062a000000000000000000000000f868da244c17cf0e288ae4a92c8636f072a7bae3000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000015180000000000000000000000000000000000000000000000000000000000000002464d623530000000000000000000000000000000000000000000000000000000000093a8000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000" | ||
"0": "0x01d5062a000000000000000000000000004626a008b1acdc4c74ab51644093b155e59a23000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000151800000000000000000000000000000000000000000000000000000000000000024763e90230000000000000000000000000000000000000000000000001286f118ca64800000000000000000000000000000000000000000000000000000000000", | ||
"1": "0xbb5a944f000000000000000000000000000000000000000000000000000000000000006e000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000003800000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000000000000000001000000000000000000000000169487a55de79476125a56b07c36ca8dbf37a3730000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000012401d5062a000000000000000000000000004626a008b1acdc4c74ab51644093b155e59a23000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000151800000000000000000000000000000000000000000000000000000000000000024763e90230000000000000000000000000000000000000000000000001286f118ca64800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000" | ||
}, | ||
"chainIds": { | ||
"0": 1, | ||
"1": 42161, | ||
"2": 137, | ||
"3": 100, | ||
"4": 43114, | ||
"5": 8453 | ||
"1": 42161 | ||
}, | ||
"description": "Set min delay for timelock", | ||
"description": "Set rate for all savings", | ||
"targets": { | ||
"0": "0x09D81464c7293C774203E46E3C921559c8E9D53f", | ||
"1": "0x896D64B4B7265273dDCD00808f3579563f9790A8", | ||
"2": "0x896D64B4B7265273dDCD00808f3579563f9790A8", | ||
"3": "0x896D64B4B7265273dDCD00808f3579563f9790A8", | ||
"4": "0x896D64B4B7265273dDCD00808f3579563f9790A8", | ||
"5": "0x896D64B4B7265273dDCD00808f3579563f9790A8" | ||
"1": "0x896D64B4B7265273dDCD00808f3579563f9790A8" | ||
}, | ||
"values": { | ||
"0": 0, | ||
"1": 100000000000000000, | ||
"2": 100000000000000000, | ||
"3": 100000000000000000, | ||
"4": 100000000000000000, | ||
"5": 100000000000000000 | ||
"1": 100000000000000000 | ||
} | ||
} |
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,32 @@ | ||
// SPDX-License-Identifier: GPL-3.0 | ||
pragma solidity ^0.8.19; | ||
|
||
import { stdJson } from "forge-std/StdJson.sol"; | ||
import { console } from "forge-std/console.sol"; | ||
import { ScriptHelpers } from "./ScriptHelpers.t.sol"; | ||
import "../../scripts/Constants.s.sol"; | ||
import { TimelockControllerWithCounter } from "contracts/TimelockControllerWithCounter.sol"; | ||
import { ProposalSender } from "contracts/ProposalSender.sol"; | ||
|
||
contract SavingsSetRateTest is ScriptHelpers { | ||
using stdJson for string; | ||
|
||
uint256 constant newRate = fourPoint3Rate; | ||
|
||
function setUp() public override { | ||
super.setUp(); | ||
} | ||
|
||
function testScript() external { | ||
uint256[] memory chainIds = _executeProposal(); | ||
|
||
// Now test that everything is as expected | ||
for (uint256 i; i < chainIds.length; i++) { | ||
uint256 chainId = chainIds[i]; | ||
ISavings stEUR = ISavings(payable(_chainToContract(chainId, ContractType.StEUR))); | ||
vm.selectFork(forkIdentifier[chainId]); | ||
uint256 rate = stEUR.rate(); | ||
assertEq(rate, newRate); | ||
} | ||
} | ||
} |
Oops, something went wrong.