-
Notifications
You must be signed in to change notification settings - Fork 1
/
testData.txt
106 lines (83 loc) · 3.1 KB
/
testData.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
customairdrop: 0xe82B3652e6ce85eB8385431f054d925f1DE1053C
testERC1155: 0x2fa7076412CC217840d2d32350550DF5cBd2d615
airdropManager: 0xB12261Ce8A7088a63C7A62ffdd568d8Fd50bee1D
Deploy Custom airdrop
Test1
0xff54A7563fc6bB7A34Ca66B41265f7f7D61b3a7D
0x2fa7076412CC217840d2d32350550DF5cBd2d615
1
100000000000000000000
1000000000000000000
1723812085
previously, the custom airdrop must transfer ownership to airdropmanager, so airdropmanager can do calls
TEST1
Call AirdropManager Contract
1. Call addAirdrop()
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
--Confirmed--
1.1 getTotalAirdropAmount: 100000000000000000000 = 100
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
2. hasExpired: false
3. isAllowed
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C (airdrop Claimer #1)
returns false
4.first call with a normal user address, not admin, fails after call with the admin address, fails also (caller 0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C)
allowAddress
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C (airdrop Claimer #1)
Should Fail - response --FAILED--
5. call allowAddress() again with admin address (caller 0xff54A7563fc6bB7A34Ca66B41265f7f7D61b3a7D (contract owner))
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C (airdrop Claimer #1)
returns successfull
6. call to isAllowed (caller 0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C) (airdrop Claimer #1)
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C
returns true
at erc1155 contract , call
7. balanceOf
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C (airdrop Claimer #1)
1
Returns 0
**this is okay because hasn't claimed yet
on AirdropManager Again call
8. claim
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C (airdrop Claimer #1)
FAILED
9. on erc1155 contract, call mint to the customairdrop contract
mint
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
1
100000000000000000000
0x
10.Chech balance of customAirdrop contract
balanceOf
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
1
response 100000000000000000000
on AirdropManager Again call (with airdrop Claimer #1)
11. claim
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C (airdrop Claimer #1)
opeartion is successfull
12.Chech balance of claimer #1 user directly in erc1155 contract
balanceOf
0x91F643a0Eb273F1b526450cAf1D2f1B711B50d1C
1
response 100000000000000000000
**new balance + airdrop amount
12. Try claim
on customAirdrop directly
claim
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0xEE0F2CA40cd73256f9cBb658A671E404931e6c4c (airdrop Claimer #2)
operation is --failed--, this is OKAY
13. Set a new admin with addAdmin()
0xD7F393DA7DED2aB940f2B7f69B37178F845dE2Dc
--successfull--
14. With the new admin (caller 0xD7F393DA7DED2aB940f2B7f69B37178F845dE2Dc), call the allowAddress function to test permissions
0xe82B3652e6ce85eB8385431f054d925f1DE1053C
0xEE0F2CA40cd73256f9cBb658A671E404931e6c4c
Response successfull