-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: skip empty withdrawable amounts
- Loading branch information
Showing
6 changed files
with
72 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 15 additions & 9 deletions
24
test/integration/basic/lockup/withdraw-max-and-transfer/withdrawMaxAndTransfer.tree
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,18 @@ | ||
withdrawMaxAndTransfer.t.sol | ||
├── when the caller is not the current recipient | ||
├── when the id references a null stream | ||
│ └── it should revert | ||
└── when the caller is the current recipient | ||
├── when the NFT has been burned | ||
└── when the id does not reference a null stream | ||
├── when the caller is not the current recipient | ||
│ └── it should revert | ||
└── when the NFT has not been burned | ||
├── it should make the max withdrawal | ||
├── it should update the withdrawn amount | ||
├── it should transfer the NFT | ||
├── it should emit a {WithdrawFromLockupStream} event | ||
└── it should emit a {Transfer} event | ||
└── when the caller is the current recipient | ||
├── when the NFT has been burned | ||
│ └── it should revert | ||
└── when the NFT has not been burned | ||
├── when the withdrawable amount is zero | ||
│ └── it should skip the withdrawal | ||
└── when the withdrawable amount is not zero | ||
├── it should make the max withdrawal | ||
├── it should update the withdrawn amount | ||
├── it should transfer the NFT | ||
├── it should emit a {WithdrawFromLockupStream} event | ||
└── it should emit a {Transfer} event |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters