Function: zapOut(address outputToken, address receiver, SingleTokenSwap swap0, SingleTokenSwap swap1, KodiakVaultUnstakingParams unstakeParams, VaultRedeemParams redeemParams)
This zaps out of a vault using a token0 or token1 swap to get outputToken.
Inputs
outputToken
Control: Fully controlled by the caller.
Constraints: N/A.
Impact: Token to be received after zap-out.
receiver
Control: Fully controlled by the caller.
Constraints: N/A.
Impact: Address to receive outputToken.
swap0
Control: Fully controlled by the caller.
Constraints: N/A.
Impact: Information of swapping token0 to outputToken.
swap1
Control: Fully controlled by the caller.
Constraints: N/A.
Impact: Information of swapping token1 to outputToken.
unstakeParams
Control: Fully controlled by the caller.
Constraints: N/A.
Impact: Information of unstaking from the Kodiak Vault.
redeemParams
Control: Fully controlled by the caller.
Constraints: N/A.
Impact: Information of redeeming from the vault.
Branches and code coverage
Intended branches
Check if the amount of token0 received by Zapper is not zero.
Check if the amount of token1 received by Zapper is not zero.
Swap token0 and token1 to outputToken.
Transfer outputToken to receiver.