Skip to content

Commit

Permalink
Fix formatting issue caused by latest forge version
Browse files Browse the repository at this point in the history
  • Loading branch information
ermyas committed Jan 29, 2024
1 parent 46aeae7 commit 417e8d4
Show file tree
Hide file tree
Showing 14 changed files with 0 additions and 45 deletions.
5 changes: 0 additions & 5 deletions test/integration/root/RootERC20BridgeFlowRate.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ contract RootERC20BridgeFlowRateIntegrationTest is
* This test uses the same code as the mapToken function does to calculate this address, so we can
* not consider it sufficient.
*/

function test_mapTokenTransfersValue() public {
address childToken =
Clones.predictDeterministicAddress(address(token), keccak256(abi.encodePacked(token)), CHILD_BRIDGE);
Expand Down Expand Up @@ -135,7 +134,6 @@ contract RootERC20BridgeFlowRateIntegrationTest is
/**
* DEPOSIT ETH
*/

function test_depositETHTransfersValue() public {
uint256 tokenAmount = 300;
setupDeposit(NATIVE_ETH, rootBridgeFlowRate, mapTokenFee, depositFee, tokenAmount, false);
Expand Down Expand Up @@ -211,7 +209,6 @@ contract RootERC20BridgeFlowRateIntegrationTest is
/**
* DEPOSIT IMX
*/

function test_depositIMXTokenTransfersValue() public {
uint256 tokenAmount = 300;

Expand Down Expand Up @@ -292,7 +289,6 @@ contract RootERC20BridgeFlowRateIntegrationTest is
/**
* DEPOSIT WETH
*/

function test_depositWETHTransfersValue() public {
uint256 tokenAmount = 300;
setupDeposit(WRAPPED_ETH, rootBridgeFlowRate, mapTokenFee, depositFee, tokenAmount, false);
Expand Down Expand Up @@ -446,7 +442,6 @@ contract RootERC20BridgeFlowRateIntegrationTest is
/**
* DEPOSIT TO
*/

function test_depositToTransfersValue() public {
uint256 tokenAmount = 300;
address recipient = address(9876);
Expand Down
7 changes: 0 additions & 7 deletions test/unit/child/ChildAxelarBridgeAdaptor.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ contract ChildAxelarBridgeAdaptorUnitTest is Test, IChildAxelarBridgeAdaptorErro
/**
* INITIALIZE
*/

function test_Initialize() public {
assertEq(address(axelarAdaptor.childBridge()), address(mockChildERC20Bridge), "childBridge not set");
assertEq(axelarAdaptor.rootChainId(), ROOT_CHAIN_NAME, "rootChain not set");
Expand Down Expand Up @@ -179,7 +178,6 @@ contract ChildAxelarBridgeAdaptorUnitTest is Test, IChildAxelarBridgeAdaptorErro
/**
* EXECUTE
*/

function test_RevertIf_executeCalledWithInvalidSourceChain() public {
bytes32 commandId = bytes32("testCommandId");
bytes memory payload = abi.encodePacked("payload");
Expand Down Expand Up @@ -221,7 +219,6 @@ contract ChildAxelarBridgeAdaptorUnitTest is Test, IChildAxelarBridgeAdaptorErro
/**
* SEND MESSAGE
*/

function test_sendMessage_CallsGasService() public {
address refundRecipient = address(123);
bytes memory payload = abi.encode(WITHDRAW_SIG, address(token), address(this), address(999), 11111);
Expand Down Expand Up @@ -342,7 +339,6 @@ contract ChildAxelarBridgeAdaptorUnitTest is Test, IChildAxelarBridgeAdaptorErro
/**
* UPDATE CHILD BRIDGE
*/

function test_updateChildBridge_UpdatesChildBridge() public {
vm.startPrank(bridgeManager);
address newChildBridge = address(0x123);
Expand Down Expand Up @@ -384,7 +380,6 @@ contract ChildAxelarBridgeAdaptorUnitTest is Test, IChildAxelarBridgeAdaptorErro
/**
* UPDATE ROOT CHAIN
*/

function test_updateRootChain_UpdatesRootChain() public {
vm.startPrank(targetManager);
string memory newRootChain = "newRoot";
Expand Down Expand Up @@ -425,7 +420,6 @@ contract ChildAxelarBridgeAdaptorUnitTest is Test, IChildAxelarBridgeAdaptorErro
/**
* UPDATE ROOT BRIDGE ADAPTOR
*/

function test_updateRootBridgeAdaptor_UpdatesRootBridgeAdaptor() public {
vm.startPrank(targetManager);
string memory newAdaptor = "newAdaptor";
Expand Down Expand Up @@ -470,7 +464,6 @@ contract ChildAxelarBridgeAdaptorUnitTest is Test, IChildAxelarBridgeAdaptorErro
/**
* UPDATE GAS SERVICE
*/

function test_updateGasService_UpdatesGasService() public {
vm.startPrank(gasServiceManager);
address newGasService = address(0x123);
Expand Down
8 changes: 0 additions & 8 deletions test/unit/child/ChildERC20Bridge.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* RECEIVE
*/

function test_NativeTransferFromWIMX() public {
address caller = address(0x123a);
payable(caller).transfer(2 ether);
Expand Down Expand Up @@ -107,7 +106,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* TREASURY DEPOSIT
*/

function test_treasuryDepostIncreasesBalance() public {
vm.deal(treasuryManager, 100 ether);
vm.startPrank(treasuryManager);
Expand Down Expand Up @@ -150,7 +148,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* INITIALIZE
*/

function test_Initialize() public {
assertEq(address(childBridge.childBridgeAdaptor()), address(address(this)), "bridgeAdaptor not set");
assertEq(childBridge.childTokenTemplate(), address(childTokenTemplate), "childTokenTemplate not set");
Expand Down Expand Up @@ -257,7 +254,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* UPDATE CHILD BRIDGE ADAPTOR
*/

function test_updateChildBridgeAdaptor_UpdatesChildBridgeAdaptor() public {
address newAdaptorAddress = address(0x11111);

Expand Down Expand Up @@ -298,7 +294,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* ON MESSAGE RECIEVE
*/

function test_onMessageReceive_SetsTokenMapping() public {
address predictedChildToken = Clones.predictDeterministicAddress(
address(childTokenTemplate), keccak256(abi.encodePacked(rootToken)), address(childBridge)
Expand Down Expand Up @@ -387,7 +382,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* DEPOSIT ETH
*/

function test_RevertsIf_OnMessageReceiveWhenPaused() public {
pause(IPausable(address(childBridge)));
bytes memory depositData =
Expand Down Expand Up @@ -461,7 +455,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* DEPOSIT
*/

function test_onMessageReceive_DepositIMX_EmitsIMXDepositEvent() public {
uint256 fundedAmount = 10 ether;
vm.deal(address(childBridge), fundedAmount);
Expand Down Expand Up @@ -616,7 +609,6 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B
/**
* WITHDRAW
*/

function test_RevertIf_WithdrawReentered() public {
// Create attack token
vm.startPrank(address(childBridge));
Expand Down
1 change: 0 additions & 1 deletion test/unit/child/withdrawals/ChildERC20BridgeWithdraw.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ contract ChildERC20BridgeWithdrawUnitTest is Test, IChildERC20BridgeEvents, IChi
/**
* WITHDRAW
*/

function test_RevertsIf_WithdrawWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ contract ChildERC20BridgeWithdrawETHUnitTest is Test, IChildERC20BridgeEvents, I
/**
* WITHDRAW ETH
*/

function test_RevertsIf_WithdrawETHWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ contract ChildERC20BridgeWithdrawETHToUnitTest is Test, IChildERC20BridgeEvents,
/**
* WITHDRAW ETH TO
*/

function test_RevertsIf_WithdrawETHToWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ contract ChildERC20BridgeWithdrawIMXUnitTest is Test, IChildERC20BridgeEvents, I
/**
* WITHDRAW IMX
*/

function test_RevertIf_WithdrawIMXWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ contract ChildERC20BridgeWithdrawIMXToUnitTest is Test, IChildERC20BridgeEvents,
/**
* WITHDRAW IMX TO
*/

function test_RevertsIf_WithdrawIMXToWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ contract ChildERC20BridgeWithdrawToUnitTest is Test, IChildERC20BridgeEvents, IC
/**
* WITHDRAW TO
*/

function test_RevertsIf_WithdrawToWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ contract ChildERC20BridgeWithdrawWIMXUnitTest is Test, IChildERC20BridgeEvents,
/**
* WITHDRAW WIMX
*/

function test_RevertsIf_WithdrawWIMXWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ contract ChildERC20BridgeWithdrawWIMXToUnitTest is Test, IChildERC20BridgeEvents
/**
* WITHDRAW WIMX TO
*/

function test_RevertsIf_WithdrawWIMXToWhenPaused() public {
pause(IPausable(address(childBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
6 changes: 0 additions & 6 deletions test/unit/root/RootAxelarBridgeAdaptor.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ contract RootAxelarBridgeAdaptorTest is Test, IRootAxelarBridgeAdaptorEvents, IR
/**
* INITIALIZE
*/

function test_Initialize() public {
assertEq(address(axelarAdaptor.rootBridge()), address(stubRootBridge), "rootBridge not set");
assertEq(axelarAdaptor.childChainId(), CHILD_CHAIN_NAME, "childChain not set");
Expand Down Expand Up @@ -281,7 +280,6 @@ contract RootAxelarBridgeAdaptorTest is Test, IRootAxelarBridgeAdaptorEvents, IR
/**
* MAP TOKEN
*/

function test_RevertIf_mapTokenCalledByNonRootBridge() public {
address payable prankster = payable(address(0x33));
uint256 value = 300;
Expand All @@ -304,7 +302,6 @@ contract RootAxelarBridgeAdaptorTest is Test, IRootAxelarBridgeAdaptorEvents, IR
/**
* UPDATE ROOT BRIDGE
*/

function test_updateRootBridge_UpdatesRootBridge() public {
vm.startPrank(bridgeManager);
address newRootBridge = address(0x3333);
Expand Down Expand Up @@ -344,7 +341,6 @@ contract RootAxelarBridgeAdaptorTest is Test, IRootAxelarBridgeAdaptorEvents, IR
/**
* UPDATE CHILD CHAIN
*/

function test_updateChildChain_UpdatesChildChain() public {
vm.startPrank(targetManager);
string memory newChildChain = "newChildChain";
Expand Down Expand Up @@ -384,7 +380,6 @@ contract RootAxelarBridgeAdaptorTest is Test, IRootAxelarBridgeAdaptorEvents, IR
/**
* UPDATE CHILD BRIDGE ADAPTOR
*/

function test_updateChildBridgeAdaptor_UpdatesChildBridgeAdaptor() public {
vm.startPrank(targetManager);

Expand Down Expand Up @@ -428,7 +423,6 @@ contract RootAxelarBridgeAdaptorTest is Test, IRootAxelarBridgeAdaptorEvents, IR
/**
* UPDATE GAS SERVICE
*/

function test_updateGasService_UpdatesGasService() public {
vm.startPrank(gasServiceManager);
address newGasService = address(0x3333);
Expand Down
8 changes: 0 additions & 8 deletions test/unit/root/RootERC20Bridge.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* INITIALIZE
*/

function test_InitializeBridge() public {
assertEq(address(rootBridge.rootBridgeAdaptor()), address(mockAxelarAdaptor), "bridgeAdaptor not set");
assertEq(rootBridge.childERC20Bridge(), CHILD_BRIDGE, "childERC20Bridge not set");
Expand Down Expand Up @@ -339,7 +338,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* MAP TOKEN
*/

function test_RevertsIf_MapTokenWhenPaused() public {
pause(IPausable(address(rootBridge)));
vm.expectRevert("Pausable: paused");
Expand Down Expand Up @@ -497,7 +495,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* DEPOSIT ETH
*/

function test_RevertsIf_DepositETHWhenPaused() public {
pause(IPausable(address(rootBridge)));
vm.expectRevert("Pausable: paused");
Expand Down Expand Up @@ -544,7 +541,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* DEPOSIT TO ETH
*/

function test_RevertsIf_DepositToETHWhenPaused() public {
pause(IPausable(address(rootBridge)));
vm.expectRevert("Pausable: paused");
Expand Down Expand Up @@ -594,7 +590,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* ZERO AMOUNT
*/

function test_RevertIf_depositETHAmountIsZero() public {
uint256 amount = 0;
setupDeposit(NATIVE_ETH, rootBridge, mapTokenFee, depositFee, amount, false);
Expand Down Expand Up @@ -633,7 +628,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* DEPOSIT WETH
*/

function test_depositWETHCallsSendMessage() public {
uint256 amount = 100;
(, bytes memory predictedPayload) =
Expand Down Expand Up @@ -708,7 +702,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* DEPOSIT TOKEN
*/

function test_RevertsIf_DepositReentered() public {
// Create attack token
ReentrancyAttackDeposit attackToken = new ReentrancyAttackDeposit(address(rootBridge));
Expand Down Expand Up @@ -916,7 +909,6 @@ contract RootERC20BridgeUnitTest is Test, IRootERC20BridgeEvents, IRootERC20Brid
/**
* DEPOSIT TO
*/

function test_RevertsIf_DepositToWhenPaused() public {
pause(IPausable(address(rootBridge)));
vm.expectRevert("Pausable: paused");
Expand Down
3 changes: 0 additions & 3 deletions test/unit/root/flowrate/RootERC20BridgeFlowRate.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,6 @@ contract RootERC20BridgeFlowRateUnitTest is
/**
* INITIALIZE
*/

function test_InitializeBridgeFlowRate() public {
assertEq(address(rootBridgeFlowRate.rootBridgeAdaptor()), address(mockAxelarAdaptor), "bridgeAdaptor not set");
assertEq(rootBridgeFlowRate.childERC20Bridge(), CHILD_BRIDGE, "childERC20Bridge not set");
Expand Down Expand Up @@ -281,7 +280,6 @@ contract RootERC20BridgeFlowRateUnitTest is
/**
* RATE ROLE ACTIONS
*/

function testActivateWithdrawalQueue() public {
vm.prank(rateAdmin);
rootBridgeFlowRate.activateWithdrawalQueue();
Expand Down Expand Up @@ -504,7 +502,6 @@ contract RootERC20BridgeFlowRateUnitTest is
/**
* FLOW RATE WITHDRAW
*/

function testWithdrawalUnconfiguredToken() public {
transferTokensToChild();

Expand Down

0 comments on commit 417e8d4

Please sign in to comment.