-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ee60e0c
commit 9131a18
Showing
1 changed file
with
25 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Tax2gas | ||
|
||
## Testcases | ||
|
||
- Normal tx success | ||
- Not supported tx will not be deducted tax amount | ||
- Forward tx should minus the amount to tx origin | ||
- Multiple forward works | ||
- Out of gas should return the tax and not consumed gas | ||
- Error forward tx should return the fund | ||
- Multiple msg types should works | ||
- Grant msg should work | ||
- Allow pay with multiple fees should work | ||
|
||
| No | Name | Scenario | Expect Result | Covered by | | ||
|----|----------|-------------------|---------------|------------| | ||
| 1 | Normal transaction should success | User transfer or make some special transactions which send coins to different address | Tax should be deducted with correct amount| | | ||
| 2 | Not supported tx will not be deducted tax amount | User transfer or make some special transactions that not in the tax list | Tax shouldn't be deducted with correct amount| | | ||
| 3 | Forward transaction should deduct the amount to tx origin | User execute contract that will trigger an execute msg to another contract | - User should be the tx origin of the execute msg<br>- Tax should be deducted with correct amount | | | ||
| 4 | Multiple forward works | Contracts will trigger another contracts multiple times | - User should be the tx origin of the execute msg<br>- Tax should be deducted with correct amount | | | ||
| 5 | Out of gas should return the tax and not consumed gas | User make some transactions with limited gas amount that will lead to cause `out of gas` error | Tax and not consumed gas should be revert to user | | | ||
| 6 | Error forward tx should return the tax and not consumed gas | User execute contract that will trigger an execute msg to another contract. The execute msg to another contract will be failed | Tax and not consumed gas should be revert to user | | | ||
| 7 | Multiple msg types should works | - Test multiple tx type that's in the tax list or not <br>- Contract dispatch multiple tx types | Chain will deduct tax with correct amount | | | ||
| 8 | Grant msg should work | User grant multiple type of permissions to different transactions | Grant permission msg will only can deduct with one denom | | | ||
| 9 | Allow pay with multiple fees should work | User make transaction with multiple coins as fee | Fee can be paid by multiple denom, if one denom is not enough, then it will deduct other denom | | |