From 7234cdd1bd720cfa2b5a4bf7fbe12cc4b91b7b84 Mon Sep 17 00:00:00 2001 From: Ermyas Abebe Date: Fri, 2 Feb 2024 11:25:12 +1100 Subject: [PATCH] Relax flow rate parameter range check --- test/fork/root/RootERC20BridgeFlowRate.t.sol | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/test/fork/root/RootERC20BridgeFlowRate.t.sol b/test/fork/root/RootERC20BridgeFlowRate.t.sol index cfe14e99..1bd4430e 100644 --- a/test/fork/root/RootERC20BridgeFlowRate.t.sol +++ b/test/fork/root/RootERC20BridgeFlowRate.t.sol @@ -206,19 +206,18 @@ contract RootERC20BridgeFlowRateForkTest is Test, Utils { function _exceedFlowRateParameters(RootERC20BridgeFlowRate bridge, address token, address withdrawer) private { (uint256 capacity, uint256 depth,, uint256 refillRate) = bridge.flowRateBuckets(token); - uint256 oneUnit = token == ETH ? 1 ether : 1 ^ IERC20Metadata(token).decimals(); // Check if the thresholds are within reasonable range assertGt( bridge.largeTransferThresholds(token), - oneUnit, - "Precondition: Large transfer threshold should be greater than 1 unit of token" + 0, + "Precondition: Large transfer threshold should be greater than zero" ); assertLt( bridge.largeTransferThresholds(token), capacity, "Precondition: Large transfer threshold should be less than capacity" ); - assertGt(capacity, oneUnit); + assertGt(capacity, 0); assertGt(refillRate, 0); assertEq(bridge.getPendingWithdrawalsLength(withdrawer), 0);