From 7967182be68501bedbf642657e8132eb80d79b71 Mon Sep 17 00:00:00 2001 From: Sujith Date: Mon, 11 Sep 2023 16:06:30 +0530 Subject: [PATCH] chore: fix nit suggested by ermyas --- test/integration-tests/RemoteAdapterAdd.t.sol | 2 +- test/unit-tests/MultiMessageSender.t.sol | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/test/integration-tests/RemoteAdapterAdd.t.sol b/test/integration-tests/RemoteAdapterAdd.t.sol index 5e4c39d..6aa7beb 100644 --- a/test/integration-tests/RemoteAdapterAdd.t.sol +++ b/test/integration-tests/RemoteAdapterAdd.t.sol @@ -64,7 +64,7 @@ contract RemoteAdapterAdd is Setup { ); bool isTrusted = - MultiMessageReceiver(contractAddress[137][bytes("MMA_RECEIVER")]).isTrustedExecutor(address(420421422)); + MultiMessageReceiver(contractAddress[137][bytes("MMA_RECEIVER")]).isTrustedExecutor(adaptersToAdd[0]); assert(isTrusted); } } diff --git a/test/unit-tests/MultiMessageSender.t.sol b/test/unit-tests/MultiMessageSender.t.sol index 9f7a0dd..42c1e77 100644 --- a/test/unit-tests/MultiMessageSender.t.sol +++ b/test/unit-tests/MultiMessageSender.t.sol @@ -105,13 +105,14 @@ contract MultiMessageSenderTest is Setup { vm.startPrank(caller); uint256 expiration = block.timestamp + EXPIRATION_CONSTANT; + uint256 nativeValue = 2 ether; uint256 balanceBefore = gac.getRefundAddress().balance; - sender.remoteCall{value: 2 ether}(DST_CHAIN_ID, address(42), bytes("42"), 0, expiration); + sender.remoteCall{value: nativeValue}(DST_CHAIN_ID, address(42), bytes("42"), 0, expiration); uint256 balanceAfter = gac.getRefundAddress().balance; uint256 fee = sender.estimateTotalMessageFee(DST_CHAIN_ID, receiver, address(42), bytes("42"), 0); - assertEq(balanceAfter - balanceBefore, 2 ether - fee); + assertEq(balanceAfter - balanceBefore, nativeValue - fee); } /// @dev perform remote call with an excluded adapter