diff --git a/test/integration/Grateful.t.sol b/test/integration/Grateful.t.sol index 5a72dad..5b10934 100644 --- a/test/integration/Grateful.t.sol +++ b/test/integration/Grateful.t.sol @@ -14,16 +14,11 @@ contract IntegrationGrateful is IntegrationBase { //////////////////////////////////////////////////////////////*/ // Tests for Standard Payments - function test_Payment( - uint256 amountMultiplier - ) public { - vm.assume(amountMultiplier > 10); - vm.assume(amountMultiplier < 1000); - + function test_Payment() public { for (uint256 i = 0; i < _tokens.length; i++) { address tokenAddr = _tokens[i]; string memory symbol = _tokenSymbols[tokenAddr]; - uint256 amount = _tokenAmounts[tokenAddr] * amountMultiplier; + uint256 amount = _tokenAmounts[tokenAddr] * 100; _approveAndPay(_user, _merchant, tokenAddr, amount, _NOT_YIELDING_FUNDS); @@ -36,12 +31,7 @@ contract IntegrationGrateful is IntegrationBase { } } - function test_PaymentYieldingFunds( - uint256 amountMultiplier - ) public { - vm.assume(amountMultiplier > 10); - vm.assume(amountMultiplier < 1000); - + function test_PaymentYieldingFunds() public { for (uint256 i = 0; i < _tokens.length; i++) { address tokenAddr = _tokens[i]; @@ -50,7 +40,7 @@ contract IntegrationGrateful is IntegrationBase { } string memory symbol = _tokenSymbols[tokenAddr]; - uint256 amount = _tokenAmounts[tokenAddr] * amountMultiplier; + uint256 amount = _tokenAmounts[tokenAddr] * 100; IERC20 token = IERC20(tokenAddr); @@ -97,12 +87,7 @@ contract IntegrationGrateful is IntegrationBase { } } - function test_PaymentYieldingFundsPartialWithdrawal( - uint256 amountMultiplier - ) public { - vm.assume(amountMultiplier > 10); - vm.assume(amountMultiplier < 1000); - + function test_PaymentYieldingFundsPartialWithdrawal() public { for (uint256 i = 0; i < _tokens.length; i++) { address tokenAddr = _tokens[i]; @@ -110,7 +95,7 @@ contract IntegrationGrateful is IntegrationBase { continue; } - uint256 amount = _tokenAmounts[tokenAddr] * amountMultiplier; + uint256 amount = _tokenAmounts[tokenAddr] * 100; // Capture owner's initial balance before payment uint256 ownerInitialBalance = IERC20(tokenAddr).balanceOf(_owner); @@ -173,16 +158,11 @@ contract IntegrationGrateful is IntegrationBase { } // Tests for One-Time Payments - function test_OneTimePayment( - uint256 amountMultiplier - ) public { - vm.assume(amountMultiplier > 10); - vm.assume(amountMultiplier < 1000); - + function test_OneTimePayment() public { for (uint256 i = 0; i < _tokens.length; i++) { address tokenAddr = _tokens[i]; string memory symbol = _tokenSymbols[tokenAddr]; - uint256 amount = _tokenAmounts[tokenAddr] * amountMultiplier; + uint256 amount = _tokenAmounts[tokenAddr] * 100; _setupAndExecuteOneTimePayment(_user, _merchant, tokenAddr, amount, _PAYMENT_SALT, _NOT_YIELDING_FUNDS); @@ -196,12 +176,7 @@ contract IntegrationGrateful is IntegrationBase { } } - function test_OneTimePaymentYieldingFunds( - uint256 amountMultiplier - ) public { - vm.assume(amountMultiplier > 10); - vm.assume(amountMultiplier < 1000); - + function test_OneTimePaymentYieldingFunds() public { for (uint256 i = 0; i < _tokens.length; i++) { address tokenAddr = _tokens[i]; @@ -210,7 +185,7 @@ contract IntegrationGrateful is IntegrationBase { } string memory symbol = _tokenSymbols[tokenAddr]; - uint256 amount = _tokenAmounts[tokenAddr] * amountMultiplier; + uint256 amount = _tokenAmounts[tokenAddr] * 100; IERC20 token = IERC20(tokenAddr); @@ -256,16 +231,11 @@ contract IntegrationGrateful is IntegrationBase { } } - function test_OverpaidOneTimePayment( - uint256 amountMultiplier - ) public { - vm.assume(amountMultiplier > 10); - vm.assume(amountMultiplier < 1000); - + function test_OverpaidOneTimePayment() public { for (uint256 i = 0; i < _tokens.length; i++) { address tokenAddr = _tokens[i]; string memory symbol = _tokenSymbols[tokenAddr]; - uint256 amount = _tokenAmounts[tokenAddr] * amountMultiplier; + uint256 amount = _tokenAmounts[tokenAddr] * 100; uint256 paymentId = _grateful.calculateId(_user, _merchant, tokenAddr, amount); address precomputed = address( @@ -312,12 +282,7 @@ contract IntegrationGrateful is IntegrationBase { } } - function test_PaymentWithCustomFee( - uint256 amountMultiplier - ) public { - vm.assume(amountMultiplier > 10); - vm.assume(amountMultiplier < 1000); - + function test_PaymentWithCustomFee() public { uint256[] memory customFees = new uint256[](3); customFees[0] = 0.02 ether; // 2% customFees[1] = 0; // 0% @@ -326,7 +291,7 @@ contract IntegrationGrateful is IntegrationBase { for (uint256 i = 0; i < _tokens.length; i++) { address tokenAddr = _tokens[i]; string memory symbol = _tokenSymbols[tokenAddr]; - uint256 amount = _tokenAmounts[tokenAddr] * amountMultiplier; + uint256 amount = _tokenAmounts[tokenAddr] * 100; uint256 expectedOwnerBalance = 0; uint256 expectedMerchantBalance = 0;