Function: depositEth(address receiver)
This function can be used to deposit ETH into the vault. The ETH is wrapped into WETH, and the receiver is minted a corresponding amount of vault shares.
Inputs
receiver
Control: Arbitrary.
Constraints: None.
Impact: Receiver of the vault shares.
Branches and code coverage
Intended branches
Wraps the received ETH, mints vault shares to the user, and updates
totalAssetValue
.
Negative behavior
Reverts if vault asset does not match WETH address returned by address provider.
Reverts if deposited value is zero.
Reverts if deposit amount is too big (cannot happen in practice).