Function: unlockDeposit(uint256 depositId, address receiver)
Unlocks deposit NFT after the lock time has passed.
Inputs
depositId
Control: Arbitrary.
Constraints: Must be the
tokenID
of a valid deposit NFT that the sender is allowed to transfer.Impact: Deposit to burn and withdraw shares of.
receiver
Control: Arbitrary.
Constraints: None.
Impact: Recipient of the shares.
Branches and code coverage
Intended branches
Unlock succeeds for the owner of NFT.
Unlock succeeds for the approved operator of NFT.
Unlock succeeds for the approved-for-all operator.
Negative behavior
Unlock fails due to nonexistent NFT.
Unlock fails due to lack of permissions.
Unlock fails due to timestamp not yet being reached.
Unlock fails due to there not being enough assets to pay for the discount.