added IntegralSwapAdapterFix.sol and set up IntegralSwapAdapter.t.sol
This commit is contained in:
@@ -2,17 +2,31 @@
|
||||
pragma solidity ^0.8.13;
|
||||
|
||||
import "forge-std/Test.sol";
|
||||
import "openzeppelin-contracts/contracts/interfaces/IERC20.sol";
|
||||
import "src/interfaces/ISwapAdapterTypes.sol";
|
||||
import "src/libraries/FractionMath.sol";
|
||||
import "src/integral/IntegralSwapAdapterFix.sol";
|
||||
|
||||
/// @title TemplateSwapAdapterTest
|
||||
/// @dev This is a template for a swap adapter test.
|
||||
/// Test all functions that are implemented in your swap adapter, the two test included here are just an example.
|
||||
/// Feel free to use UniswapV2SwapAdapterTest and BalancerV2SwapAdapterTest as a reference.
|
||||
contract TemplateSwapAdapterTest is Test, ISwapAdapterTypes {
|
||||
contract IntegralSwapAdapterTest is Test, ISwapAdapterTypes {
|
||||
using FractionMath for Fraction;
|
||||
|
||||
function testPriceFuzz(uint256 amount0, uint256 amount1) public {}
|
||||
IntegralSwapAdapter adapter;
|
||||
IERC20 constant WETH = IERC20(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2);
|
||||
IERC20 constant USDC = IERC20(0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48);
|
||||
address constant USDC_WETH_PAIR = 0x2fe16Dd18bba26e457B7dD2080d5674312b026a2;
|
||||
address constant relayerAddress = 0xd17b3c9784510E33cD5B87b490E79253BcD81e2E;
|
||||
|
||||
uint256 constant TEST_ITERATIONS = 100;
|
||||
|
||||
function setUp() public {
|
||||
uint256 forkBlock = 18835309;
|
||||
vm.createSelectFork(vm.rpcUrl("mainnet"), forkBlock);
|
||||
adapter = new IntegralSwapAdapter(relayerAddress);
|
||||
|
||||
vm.label(address(WETH), "WETH");
|
||||
vm.label(address(USDC), "USDC");
|
||||
vm.label(address(USDC_WETH_PAIR), "USDC_WETH_PAIR");
|
||||
|
||||
}
|
||||
|
||||
function testSwapFuzz(uint256 specifiedAmount) public {}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user