Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: added gg deployment tests. #20

Merged
merged 6 commits into from
Jun 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions deployments/avalanche.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0x617332a777780F546261247F621051d0b98975Eb",
"lzAdapter": "0x10f02995a399C0dC0FaF29914220E9C1bCdE8640",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/base.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0x0000000000000000000000000000000000000000",
"lzAdapter": "0x0000000000000000000000000000000000000000",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/binance.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0x3F006299eC88985c18E6e885EeA29A49eC579882",
"lzAdapter": "0xa5cc218513305221201f196760E9e64e9D49d98A",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/celo.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0xa5cc218513305221201f196760E9e64e9D49d98A",
"lzAdapter": "0xAE93BEa44dcbE52B625169588574d31e36fb3A67",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x3F006299eC88985c18E6e885EeA29A49eC579882",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/gnosis.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x3C06dce358add17aAf230f2234bCCC4afd50d090",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0xA806DA549FcB2B4912a7dFFE4c1aA7A1ed0Bd5C9",
"lzAdapter": "0x9b6f5ef589A3DD08670Dd146C11C4Fb33E04494F",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/metis.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0x0000000000000000000000000000000000000000",
"lzAdapter": "0x0000000000000000000000000000000000000000",
"metisAdapter": "0xf41193E25408F652AF878c47E4401A01B5E4B682",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/optimism.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0x0000000000000000000000000000000000000000",
"lzAdapter": "0x0000000000000000000000000000000000000000",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/polygon.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0x3e72665008dC237bdd91C04C10782Ed1987a4019",
"lzAdapter": "0x7FAE7765abB4c8f778d57337bB720d0BC53057e3",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x0000000000000000000000000000000000000000",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
6 changes: 4 additions & 2 deletions deployments/scroll.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"emergencyRegistry": "0x0000000000000000000000000000000000000000",
"gnosisAdapter": "0x0000000000000000000000000000000000000000",
"guardian": "0xEAF6183bAb3eFD3bF856Ac5C058431C8592394d6",
"granularCCCGuardian": "0x0000000000000000000000000000000000000000",
"hlAdapter": "0x0000000000000000000000000000000000000000",
"lzAdapter": "0x0000000000000000000000000000000000000000",
"metisAdapter": "0x0000000000000000000000000000000000000000",
Expand All @@ -22,5 +23,6 @@
"sameChainAdapter": "0x0000000000000000000000000000000000000000",
"scrollAdapter": "0x3C06dce358add17aAf230f2234bCCC4afd50d090",
"wormholeAdapter": "0x0000000000000000000000000000000000000000",
"zkevmAdapter": "0x0000000000000000000000000000000000000000"
}
"zkevmAdapter": "0x0000000000000000000000000000000000000000",
"zksyncAdapter": "0x0000000000000000000000000000000000000000"
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
{
"receiverAdaptersByChain": {
"1": {
"0x1Cfe182fa075EF185adFD605806241e2d181ffC2": {
"0x10c0dE4236d3725b110BC890faec301E8b49E45F": {
"from": null,
"to": true
}
Expand Down
4 changes: 2 additions & 2 deletions foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ optimism="${RPC_OPTIMISM}"
optimism-testnet="${RPC_OPTIMISM_TESTNET}"
fantom="${RPC_FANTOM}"
fantom-testnet="${RPC_FANTOM_TESTNET}"
binance="${RPC_BINANCE}"
binance-testnet="${RPC_BINANCE_TESTNET}"
binance="${RPC_BNB}"
binance-testnet="${RPC_BNB_TESTNET}"
base="${RPC_BASE}"
base-testnet="${RPC_BASE_TESTNET}"
gnosis="${RPC_GNOSIS}"
Expand Down
1 change: 1 addition & 0 deletions remappings.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@ aave-helpers/=lib/aave-delivery-infrastructure/lib/aave-helpers/src/
aave-address-book/=lib/aave-delivery-infrastructure/lib/aave-helpers/lib/aave-address-book/src/
adi/=lib/aave-delivery-infrastructure/src/contracts/
adi-scripts/=lib/aave-delivery-infrastructure/scripts/
adi-tests/=lib/aave-delivery-infrastructure/tests/


2 changes: 1 addition & 1 deletion reports/adi_test_adi_diffs_after.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"forwarderAdaptersByChain": {},
"receiverAdaptersByChain": {
"1": {
"0x1Cfe182fa075EF185adFD605806241e2d181ffC2": true,
"0x10c0dE4236d3725b110BC890faec301E8b49E45F": true,
"0xc8a2ADC4261c6b669CdFf69E717E77C9cFeB420d": true
}
},
Expand Down
15 changes: 15 additions & 0 deletions reports/adi_test_adi_diffs_before.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"chainId": 42161,
"forwarderAdaptersByChain": {},
"receiverAdaptersByChain": {
"1": {
"0xc8a2ADC4261c6b669CdFf69E717E77C9cFeB420d": true
}
},
"receiverConfigs": {
"1": {
"requiredConfirmations": 1,
"validityTimestamp": 0
}
}
}
3 changes: 0 additions & 3 deletions scripts/access_control/DeployGranularGuardian.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ contract Ethereum is DeployGranularGuardian {
function SOLVE_EMERGENCY_GUARDIAN() internal pure override returns (address) {
return MiscEthereum.PROTOCOL_GUARDIAN;
}

}

contract Avalanche is DeployGranularGuardian {
Expand All @@ -63,8 +62,6 @@ contract Avalanche is DeployGranularGuardian {
return MiscAvalanche.PROTOCOL_GUARDIAN;
}



function TRANSACTION_NETWORK() internal pure override returns (uint256) {
return ChainIds.AVALANCHE;
}
Expand Down
30 changes: 30 additions & 0 deletions tests/BaseTest.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// SPDX-License-Identifier: BUSL-1.1
pragma solidity ^0.8.0;

import 'forge-std/Test.sol';

contract BaseTest is Test {
bytes internal constant MESSAGE = bytes('this is the message to send');

modifier executeAs(address executor) {
vm.startPrank(executor);
_;
vm.stopPrank();
}

modifier filterAddress(address addressToFilter) {
_filterAddress(addressToFilter);
_;
}

function _filterAddress(address addressToFilter) internal pure {
vm.assume(
addressToFilter != address(0) &&
addressToFilter != 0xCe71065D4017F316EC606Fe4422e11eB2c47c246 && // FuzzerDict
addressToFilter != 0x4e59b44847b379578588920cA78FbF26c0B4956C && // CREATE2 Factory (?)
addressToFilter != 0xb4c79daB8f259C7Aee6E5b2Aa729821864227e84 && // address(this)
addressToFilter != 0x185a4dc360CE69bDCceE33b3784B0282f7961aea && // ???
addressToFilter != 0x7109709ECfa91a80626fF3989D68f67F5b1DD12D // cheat codes
);
}
}
Loading
Loading