diff --git a/test/CustomAccounting.t.sol b/test/CustomAccounting.t.sol index 9e35d344f..9ce42b73f 100644 --- a/test/CustomAccounting.t.sol +++ b/test/CustomAccounting.t.sol @@ -152,11 +152,11 @@ contract CustomAccountingTest is Test, Deployers, GasSnapshot { assertEq(currency1.balanceOf(address(this)), balanceBefore1 + amountToSwap, "amount 1"); } - // maximum available liquidity in each direction for the pool in test_fuzz_swap_beforeSwap_returnsDeltaSpecified + // maximum available liquidity in each direction for the pool in test_swap_beforeSwap_returnsDeltaSpecified_fuzz int128 maxPossibleIn_fuzz_test = -6018336102428409; int128 maxPossibleOut_fuzz_test = 5981737760509662; - function test_fuzz_swap_beforeSwap_returnsDeltaSpecified( + function test_swap_beforeSwap_returnsDeltaSpecified_fuzz( int128 hookDeltaSpecified, int256 amountSpecified, bool zeroForOne diff --git a/test/DynamicFees.t.sol b/test/DynamicFees.t.sol index 7fcf7b25f..de244bb2c 100644 --- a/test/DynamicFees.t.sol +++ b/test/DynamicFees.t.sol @@ -267,7 +267,7 @@ contract TestDynamicFees is Test, Deployers, GasSnapshot { assertEq(_fetchPoolLPFee(key), 123); } - function test_fuzz_ProtocolAndLPFee(uint24 lpFee, uint16 protocolFee0, uint16 protocolFee1, int256 amountSpecified) + function test_ProtocolAndLPFee_fuzz(uint24 lpFee, uint16 protocolFee0, uint16 protocolFee1, int256 amountSpecified) public { assertEq(_fetchPoolLPFee(key), 0); diff --git a/test/DynamicReturnFees.t.sol b/test/DynamicReturnFees.t.sol index 645c67237..d1f2d9a30 100644 --- a/test/DynamicReturnFees.t.sol +++ b/test/DynamicReturnFees.t.sol @@ -59,7 +59,7 @@ contract TestDynamicReturnFees is Test, Deployers, GasSnapshot { ); } - function test_fuzz_dynamicReturnSwapFee(uint24 fee) public { + function test_dynamicReturnSwapFee_fuzz(uint24 fee) public { // hook will handle adding the override flag dynamicReturnFeesHook.setFee(fee); diff --git a/test/Extsload.t.sol b/test/Extsload.t.sol index 3bae1ebe9..00dd77ac3 100644 --- a/test/Extsload.t.sol +++ b/test/Extsload.t.sol @@ -26,7 +26,7 @@ contract ExtsloadTest is Test, GasSnapshot { } } - function test_fuzz_extsload(uint256 length, uint256 seed, bytes memory dirtyBits) public { + function test_extsload_fuzz(uint256 length, uint256 seed, bytes memory dirtyBits) public { length = bound(length, 0, 1000); bytes32[] memory slots = new bytes32[](length); bytes32[] memory expected = new bytes32[](length); diff --git a/test/ModifyLiquidity.t.sol b/test/ModifyLiquidity.t.sol index 5cf4687b5..2de229d18 100644 --- a/test/ModifyLiquidity.t.sol +++ b/test/ModifyLiquidity.t.sol @@ -50,7 +50,7 @@ contract ModifyLiquidityTest is Test, Logger, Deployers, JavascriptFfi, Fuzzers, /// forge-config: default.fuzz.runs = 10 /// forge-config: pr.fuzz.runs = 10 /// forge-config: ci.fuzz.runs = 500 - function test_ffi_fuzz_addLiquidity_defaultPool_ReturnsCorrectLiquidityDelta( + function test_ffi_addLiquidity_defaultPool_ReturnsCorrectLiquidityDelta_fuzz( IPoolManager.ModifyLiquidityParams memory paramSeed ) public { // Sanitize the fuzzed params to get valid tickLower, tickUpper, and liquidityDelta. diff --git a/test/PoolManagerInitialize.t.sol b/test/PoolManagerInitialize.t.sol index 1bcb00a76..e89761657 100644 --- a/test/PoolManagerInitialize.t.sol +++ b/test/PoolManagerInitialize.t.sol @@ -53,7 +53,7 @@ contract PoolManagerInitializeTest is Test, Deployers, GasSnapshot { }); } - function test_fuzz_initialize(PoolKey memory key0, uint160 sqrtPriceX96) public { + function test_initialize_fuzz(PoolKey memory key0, uint160 sqrtPriceX96) public { // Assumptions tested in Pool.t.sol sqrtPriceX96 = uint160(bound(sqrtPriceX96, TickMath.MIN_SQRT_PRICE, TickMath.MAX_SQRT_PRICE - 1)); diff --git a/test/ProtocolFeesImplementation.t.sol b/test/ProtocolFeesImplementation.t.sol index 462999b9d..12521736c 100644 --- a/test/ProtocolFeesImplementation.t.sol +++ b/test/ProtocolFeesImplementation.t.sol @@ -86,7 +86,7 @@ contract ProtocolFeesTest is Test, GasSnapshot, Deployers { protocolFees.setProtocolFee(key, MAX_PROTOCOL_FEE_BOTH_TOKENS + (1 << 12)); } - function test_fuzz_setProtocolFee(PoolKey memory key, uint24 protocolFee) public { + function test_setProtocolFee_fuzz(PoolKey memory key, uint24 protocolFee) public { protocolFees.setProtocolFeeController(feeController); // Set price to pretend that the pool is initialized protocolFees.setPrice(key, Constants.SQRT_PRICE_1_1); @@ -120,7 +120,7 @@ contract ProtocolFeesTest is Test, GasSnapshot, Deployers { assertEq(currency0.balanceOf(address(this)), 100); } - function test_fuzz_collectProtocolFees(address recipient, uint256 amount, uint256 feesAccrued) public { + function test_collectProtocolFees_fuzz(address recipient, uint256 amount, uint256 feesAccrued) public { vm.assume(feesAccrued <= currency0.balanceOf(address(protocolFees))); uint256 recipientBalanceBefore = currency0.balanceOf(recipient); @@ -161,7 +161,7 @@ contract ProtocolFeesTest is Test, GasSnapshot, Deployers { assertEq(protocolFees.protocolFeesAccrued(currency0), 300); } - function test_fuzz_updateProtocolFees(uint256 amount, uint256 startingAmount) public { + function test_updateProtocolFees_fuzz(uint256 amount, uint256 startingAmount) public { // set a starting balance of protocol fees protocolFees.updateProtocolFees(currency0, startingAmount); assertEq(protocolFees.protocolFeesAccrued(currency0), startingAmount); diff --git a/test/Reserves.t.sol b/test/Reserves.t.sol index 99c5ada75..f56649156 100644 --- a/test/Reserves.t.sol +++ b/test/Reserves.t.sol @@ -42,7 +42,7 @@ contract ReservesTest is Test { assertEq(bytes32(uint256(keccak256("ReservesOf")) - 1), Reserves.RESERVES_OF_SLOT); } - function test_fuzz_get_set(Currency currency, uint256 value) public { + function test_get_set_fuzz(Currency currency, uint256 value) public { vm.assume(value != type(uint256).max); currency.setReserves(value); assertEq(currency.getReserves(), value); diff --git a/test/libraries/BitMath.t.sol b/test/libraries/BitMath.t.sol index dcc0295a0..cb36f09bc 100644 --- a/test/libraries/BitMath.t.sol +++ b/test/libraries/BitMath.t.sol @@ -30,7 +30,7 @@ contract TestBitMath is Test, GasSnapshot { assertEq(BitMath.mostSignificantBit(type(uint256).max), 255); } - function test_fuzz_mostSignificantBit(uint256 x) public pure { + function test_mostSignificantBit_fuzz(uint256 x) public pure { vm.assume(x != 0); assertEq(BitMath.mostSignificantBit(x), mostSignificantBitReference(x)); } @@ -80,7 +80,7 @@ contract TestBitMath is Test, GasSnapshot { assertEq(BitMath.leastSignificantBit(type(uint256).max), 0); } - function test_fuzz_leastSignificantBit(uint256 x) public pure { + function test_leastSignificantBit_fuzz(uint256 x) public pure { vm.assume(x != 0); assertEq(BitMath.leastSignificantBit(x), leastSignificantBitReference(x)); } diff --git a/test/libraries/FullMath.t.sol b/test/libraries/FullMath.t.sol index 5978e351b..026519d19 100644 --- a/test/libraries/FullMath.t.sol +++ b/test/libraries/FullMath.t.sol @@ -10,7 +10,7 @@ contract FullMathTest is Test { uint256 constant Q128 = 2 ** 128; uint256 constant MAX_UINT256 = type(uint256).max; - function test_fuzz_mulDiv_revertsWith0Denominator(uint256 x, uint256 y) public { + function test_mulDiv_revertsWith0Denominator_fuzz(uint256 x, uint256 y) public { vm.expectRevert(); x.mulDiv(y, 0); } @@ -49,14 +49,14 @@ contract FullMathTest is Test { assertEq(Q128.mulDiv(1000 * Q128, 3000 * Q128), result); } - function test_fuzz_mulDiv(uint256 x, uint256 y, uint256 d) public pure { + function test_mulDiv_fuzz(uint256 x, uint256 y, uint256 d) public pure { vm.assume(d != 0); vm.assume(y != 0); x = bound(x, 0, type(uint256).max / y); assertEq(FullMath.mulDiv(x, y, d), x * y / d); } - function test_fuzz_mulDivRoundingUp_revertsWith0Denominator(uint256 x, uint256 y) public { + function test_mulDivRoundingUp_revertsWith0Denominator_fuzz(uint256 x, uint256 y) public { vm.expectRevert(); x.mulDivRoundingUp(y, 0); } @@ -94,7 +94,7 @@ contract FullMathTest is Test { ); } - function test_fuzz_mulDivRoundingUp(uint256 x, uint256 y, uint256 d) public pure { + function test_mulDivRoundingUp_fuzz(uint256 x, uint256 y, uint256 d) public pure { vm.assume(d != 0); vm.assume(y != 0); x = bound(x, 0, type(uint256).max / y); diff --git a/test/libraries/Hooks.t.sol b/test/libraries/Hooks.t.sol index f6d951288..920ae2a55 100644 --- a/test/libraries/Hooks.t.sol +++ b/test/libraries/Hooks.t.sol @@ -194,7 +194,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { } // hook validation - function test_fuzz_validateHookPermissions_noHooks(uint160 addr) public view { + function test_validateHookPermissions_noHooks_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(preAddr)); @@ -233,7 +233,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeInitialize(uint160 addr) public view { + function test_validateHookPermissions_beforeInitialize_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_INITIALIZE_FLAG))); @@ -272,7 +272,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_afterInitialize(uint160 addr) public view { + function test_validateHookPermissions_afterInitialize_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.AFTER_INITIALIZE_FLAG))); @@ -311,7 +311,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeAndAfterInitialize(uint160 addr) public view { + function test_validateHookPermissions_beforeAndAfterInitialize_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_INITIALIZE_FLAG | Hooks.AFTER_INITIALIZE_FLAG))); Hooks.validateHookPermissions( @@ -349,7 +349,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeAddLiquidity(uint160 addr) public view { + function test_validateHookPermissions_beforeAddLiquidity_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_ADD_LIQUIDITY_FLAG))); Hooks.validateHookPermissions( @@ -387,7 +387,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_afterAddLiquidity(uint160 addr) public view { + function test_validateHookPermissions_afterAddLiquidity_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.AFTER_ADD_LIQUIDITY_FLAG))); Hooks.validateHookPermissions( @@ -425,7 +425,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeAndAfterAddLiquidity(uint160 addr) public view { + function test_validateHookPermissions_beforeAndAfterAddLiquidity_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_ADD_LIQUIDITY_FLAG | Hooks.AFTER_ADD_LIQUIDITY_FLAG))); @@ -464,7 +464,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeRemoveLiquidity(uint160 addr) public view { + function test_validateHookPermissions_beforeRemoveLiquidity_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_REMOVE_LIQUIDITY_FLAG))); Hooks.validateHookPermissions( @@ -502,7 +502,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_afterRemoveLiquidity(uint160 addr) public view { + function test_validateHookPermissions_afterRemoveLiquidity_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.AFTER_REMOVE_LIQUIDITY_FLAG))); Hooks.validateHookPermissions( @@ -540,7 +540,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeAfterRemoveLiquidity(uint160 addr) public view { + function test_validateHookPermissions_beforeAfterRemoveLiquidity_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_REMOVE_LIQUIDITY_FLAG | Hooks.AFTER_REMOVE_LIQUIDITY_FLAG))); @@ -579,7 +579,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeInitializeAfterAddLiquidity(uint160 addr) public view { + function test_validateHookPermissions_beforeInitializeAfterAddLiquidity_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_INITIALIZE_FLAG | Hooks.AFTER_ADD_LIQUIDITY_FLAG))); @@ -618,7 +618,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeSwap(uint160 addr) public view { + function test_validateHookPermissions_beforeSwap_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_SWAP_FLAG))); Hooks.validateHookPermissions( @@ -656,7 +656,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_afterSwap(uint160 addr) public view { + function test_validateHookPermissions_afterSwap_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.AFTER_SWAP_FLAG))); Hooks.validateHookPermissions( @@ -694,7 +694,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeAndAfterSwap(uint160 addr) public view { + function test_validateHookPermissions_beforeAndAfterSwap_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_SWAP_FLAG | Hooks.AFTER_SWAP_FLAG))); Hooks.validateHookPermissions( @@ -732,7 +732,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeDonate(uint160 addr) public view { + function test_validateHookPermissions_beforeDonate_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_DONATE_FLAG))); Hooks.validateHookPermissions( @@ -770,7 +770,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_afterDonate(uint160 addr) public view { + function test_validateHookPermissions_afterDonate_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.AFTER_DONATE_FLAG))); Hooks.validateHookPermissions( @@ -808,7 +808,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_beforeAndAfterDonate(uint160 addr) public view { + function test_validateHookPermissions_beforeAndAfterDonate_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_DONATE_FLAG | Hooks.AFTER_DONATE_FLAG))); Hooks.validateHookPermissions( @@ -846,7 +846,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookPermissions_allHooks(uint160 addr) public view { + function test_validateHookPermissions_allHooks_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; uint160 allHookBitsFlipped = uint160((1 << hookPermissionCount) - 1); IHooks hookAddr = IHooks(address(uint160(preAddr) | allHookBitsFlipped)); @@ -885,7 +885,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertTrue(hookAddr.hasPermission(Hooks.AFTER_REMOVE_LIQUIDITY_RETURNS_DELTA_FLAG)); } - function test_fuzz_validateHookAddress_failsAllHooks(uint160 addr, uint16 mask) public { + function test_validateHookAddress_failsAllHooks_fuzz(uint160 addr, uint16 mask) public { uint160 preAddr = addr & clearAllHookPermissionsMask; // Set the upper `hooksPermissionCount` number of bits to get the full mask in uint16. uint16 allHooksMask = uint16(~uint16(0)); @@ -914,7 +914,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { ); } - function test_fuzz_validateHookAddress_failsNoHooks(uint160 addr, uint16 mask) public { + function test_validateHookAddress_failsNoHooks_fuzz(uint160 addr, uint16 mask) public { // we only want hookPermissionCount of mask mask = mask >> (16 - hookPermissionCount); uint160 preAddr = addr & clearAllHookPermissionsMask; @@ -965,7 +965,7 @@ contract HooksTest is Test, Deployers, GasSnapshot { assertFalse(Hooks.isValidHookAddress(IHooks(address(0)), LPFeeLibrary.DYNAMIC_FEE_FLAG)); } - function test_fuzz_isValidHookAddress_invalid_returnsDeltaWithoutHookFlag(uint160 addr) public view { + function test_isValidHookAddress_invalid_returnsDeltaWithoutHookFlag_fuzz(uint160 addr) public view { uint160 preAddr = addr & clearAllHookPermissionsMask; IHooks hookAddr = IHooks(address(uint160(preAddr | Hooks.BEFORE_SWAP_RETURNS_DELTA_FLAG))); assertFalse(Hooks.isValidHookAddress(hookAddr, 3000)); diff --git a/test/libraries/LPFeeLibrary.t.sol b/test/libraries/LPFeeLibrary.t.sol index a6cde42f6..6f8efcf68 100644 --- a/test/libraries/LPFeeLibrary.t.sol +++ b/test/libraries/LPFeeLibrary.t.sol @@ -21,7 +21,7 @@ contract LPFeeLibraryTest is Test { assertFalse(LPFeeLibrary.isDynamicFee(dynamicFee)); } - function test_fuzz_isDynamicFee(uint24 fee) public pure { + function test_isDynamicFee_fuzz(uint24 fee) public pure { assertEq(fee == LPFeeLibrary.DYNAMIC_FEE_FLAG, LPFeeLibrary.isDynamicFee(fee)); } @@ -46,7 +46,7 @@ contract LPFeeLibraryTest is Test { LPFeeLibrary.validate(fee); } - function test_fuzz_validate(uint24 fee) public { + function test_validate_fuzz(uint24 fee) public { if (fee > 1000000) { vm.expectRevert(LPFeeLibrary.FeeTooLarge.selector); } @@ -75,7 +75,7 @@ contract LPFeeLibraryTest is Test { LPFeeLibrary.getInitialLPFee(dynamicFee); } - function test_fuzz_getInitialLPFee(uint24 fee) public { + function test_getInitialLPFee_fuzz(uint24 fee) public { if (fee == LPFeeLibrary.DYNAMIC_FEE_FLAG) { assertEq(LPFeeLibrary.getInitialLPFee(fee), 0); } else if (fee > 1000000) { diff --git a/test/libraries/NonZeroDeltaCount.t.sol b/test/libraries/NonZeroDeltaCount.t.sol index 6451b60fc..8e46786fa 100644 --- a/test/libraries/NonZeroDeltaCount.t.sol +++ b/test/libraries/NonZeroDeltaCount.t.sol @@ -21,7 +21,7 @@ contract NonZeroDeltaCountTest is Test { // Reading from right to left. Bit of 0: call increase. Bit of 1: call decrease. // The library allows over over/underflow so we dont check for that here - function test_fuzz_nonZeroDeltaCount(uint256 instructions) public { + function test_nonZeroDeltaCount_fuzz(uint256 instructions) public { assertEq(NonZeroDeltaCount.read(), 0); uint256 expectedCount; for (uint256 i = 0; i < 256; i++) { diff --git a/test/libraries/Pool.t.sol b/test/libraries/Pool.t.sol index 0673e18f2..04a63b347 100644 --- a/test/libraries/Pool.t.sol +++ b/test/libraries/Pool.t.sol @@ -91,7 +91,7 @@ contract PoolTest is Test, GasSnapshot { state.modifyLiquidity(params); } - function test_fuzz_swap( + function test_swap_fuzz( uint160 sqrtPriceX96, uint24 lpFee, uint16 protocolFee0, @@ -168,7 +168,7 @@ contract PoolTest is Test, GasSnapshot { } } - function test_fuzz_tickSpacingToMaxLiquidityPerTick(int24 tickSpacing) public pure { + function test_tickSpacingToMaxLiquidityPerTick_fuzz(int24 tickSpacing) public pure { tickSpacing = int24(bound(tickSpacing, TickMath.MIN_TICK_SPACING, TickMath.MAX_TICK_SPACING)); // v3 math int24 minTick = (TickMath.MIN_TICK / tickSpacing) * tickSpacing; diff --git a/test/libraries/PoolId.t.sol b/test/libraries/PoolId.t.sol index 24dfbee4b..b201d7185 100644 --- a/test/libraries/PoolId.t.sol +++ b/test/libraries/PoolId.t.sol @@ -8,7 +8,7 @@ import {PoolKey} from "../../src/types/PoolKey.sol"; contract PoolIdTest is Test { using PoolIdLibrary for PoolKey; - function test_fuzz_toId(PoolKey memory poolKey) public pure { + function test_toId_fuzz(PoolKey memory poolKey) public pure { bytes memory encodedKey = abi.encode(poolKey); bytes32 expectedHash = keccak256(encodedKey); assertEq(PoolId.unwrap(poolKey.toId()), expectedHash, "hashes not equal"); diff --git a/test/libraries/Position.t.sol b/test/libraries/Position.t.sol index cd64893d5..1640b605b 100644 --- a/test/libraries/Position.t.sol +++ b/test/libraries/Position.t.sol @@ -10,7 +10,7 @@ contract PositionTest is Test { mapping(bytes32 => Position.Info) internal positions; - function test_fuzz_get(address owner, int24 tickLower, int24 tickUpper, bytes32 salt) public view { + function test_get_fuzz(address owner, int24 tickLower, int24 tickUpper, bytes32 salt) public view { bytes32 positionKey = keccak256(abi.encodePacked(owner, tickLower, tickUpper, salt)); Position.Info storage expectedPosition = positions[positionKey]; Position.Info storage position = positions.get(owner, tickLower, tickUpper, salt); @@ -23,7 +23,7 @@ contract PositionTest is Test { assertEq(positionSlot, expectedPositionSlot, "slots not equal"); } - function test_fuzz_update( + function test_update_fuzz( int128 liquidityDelta, Position.Info memory pos, uint256 newFeeGrowthInside0X128,