feat: Proper USV3Executor transfer decoding + tests

- Properly decode, update tests with proper decoding
- Added test case for each transfer method
- Also fully tested permit2 transferFrom and it works perfectly.

NOTE:
UniswapV3 doesn't support NONE as a transfer method.

TODO:
- Fix integration tests once encoding is implemented.
This commit is contained in:
TAMARA LIPOWSKI
2025-04-08 16:40:01 -04:00
committed by Diana Carvalho
parent 30557e7e54
commit e3ac394d27
4 changed files with 115 additions and 12 deletions

View File

@@ -198,7 +198,13 @@ contract TychoRouterTestSetup is Constants, Permit2TestHelper {
) internal view returns (bytes memory) {
IUniswapV3Pool pool = IUniswapV3Pool(target);
return abi.encodePacked(
tokenIn, tokenOut, pool.fee(), receiver, target, zero2one
tokenIn,
tokenOut,
pool.fee(),
receiver,
target,
zero2one,
ExecutorTransferMethods.TransferMethod.TRANSFER
);
}
}