type PermitSignature = { amount: tStringCurrencyUnits; deadline: string; v: number; r: BytesLike; s: BytesLike; }; await lendingPool.swapCollateral({ user, // string; flash, // ? boolean; fromAsset, // string; fromAToken, // string; toAsset, // string; fromAmount, // string; ...
{ LENDING_POOL: lendingPoolAddress, SWAP_COLLATERAL_ADAPTER: swapCollateralAdapterAddress, WETH_GATEWAY: wethGatewayAddress, }); /* - @param `user` The ethereum address that will liquidate the position - @param @optional `flash` If the transaction will be executed through a flashloan(true) ...
5 passed; 0 failed; 0 skipped; finished in 1.29ms (194.57µs CPU time) Ran 17 tests for tests/extensions/paraswap-adapters/ParaswapAdapters.t.sol:ParaswapAdaptersTest [PASS] test_rescueTokens() (gas: 203409) [PASS] test_reverts_offset_out_of_range_swap_liquidity_permit_flashloan() (...
635 | | Faucet | 2,064 | 2,596 | 22,512 | 46,556 | | FlashLoanLogic | 9,520 | 9,573 | 15,056 | 39,579 | | FlashloanAttacker | 2,123 | 2,547 | 22,453 | 46,605 | | GPv2SafeERC20 | 44 | 94 | 24,532 | 49,058 | | GenericLogic | 44 | 94 | 24,532 | 49...
635 | | Faucet | 2,064 | 2,596 | 22,512 | 46,556 | | FlashLoanLogic | 9,520 | 9,573 | 15,056 | 39,579 | | FlashloanAttacker | 2,123 | 2,547 | 22,453 | 46,605 | | GPv2SafeERC20 | 44 | 94 | 24,532 | 49,058 | | GenericLogic | 44 | 94 | 24,532 | 49...
5 passed; 0 failed; 0 skipped; finished in 1.40ms (225.13µs CPU time) Ran 17 tests for tests/extensions/paraswap-adapters/ParaswapAdapters.t.sol:ParaswapAdaptersTest [PASS] test_rescueTokens() (gas: 203341) [PASS] test_reverts_offset_out_of_range_swap_liquidity_permit_flashloan() (...
12 passed; 0 failed; 0 skipped; finished in 30.09ms (18.12ms CPU time) Ran 17 tests for tests/extensions/paraswap-adapters/ParaswapAdapters.t.sol:ParaswapAdaptersTest [PASS] test_rescueTokens() (gas: 203447) [PASS] test_reverts_offset_out_of_range_swap_liquidity_permit_flashloan() (gas:...
4 passed; 0 failed; 0 skipped; finished in 45.91ms (1.06ms CPU time) Ran 17 tests for tests/extensions/paraswap-adapters/ParaswapAdapters.t.sol:ParaswapAdaptersTest [PASS] test_rescueTokens() (gas: 196298) [PASS] test_reverts_offset_out_of_range_swap_liquidity_permit_flashloan() (gas: ...
Defaults to false */ const txs: EthereumTransactionTypeExtended[] = await lendingPool.swapCollateral( { user, flash, fromAsset, fromAToken, toAsset, fromAmount, toAmount, maxSlippage, permitSignature, swapAll, onBehalfOf, referralCode, useEthPath, }, ); Submit transaction(s) as shown here...