Skip to content

Commit 49ae33f

Browse files
authored
Add e2e tests (#2655)
* Add e2e tests * fix * fix * update tests * update tests * fix tests * Apply suggestions * update dependencies * fix tests
1 parent 1fd9251 commit 49ae33f

29 files changed

+8456
-7685
lines changed

ts-tests/build/Block.json

Lines changed: 247 additions & 247 deletions
Large diffs are not rendered by default.

ts-tests/build/ChildContract.json

Lines changed: 40 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -32,48 +32,48 @@
3232
{
3333
"ast": {
3434
"nodeType": "YulBlock",
35-
"src": "0:439:16",
35+
"src": "0:439:17",
3636
"statements": [
3737
{
3838
"body": {
3939
"nodeType": "YulBlock",
40-
"src": "72:53:16",
40+
"src": "72:53:17",
4141
"statements": [
4242
{
4343
"expression": {
4444
"arguments": [
4545
{
4646
"name": "pos",
4747
"nodeType": "YulIdentifier",
48-
"src": "89:3:16"
48+
"src": "89:3:17"
4949
},
5050
{
5151
"arguments": [
5252
{
5353
"name": "value",
5454
"nodeType": "YulIdentifier",
55-
"src": "112:5:16"
55+
"src": "112:5:17"
5656
}
5757
],
5858
"functionName": {
5959
"name": "cleanup_t_uint256",
6060
"nodeType": "YulIdentifier",
61-
"src": "94:17:16"
61+
"src": "94:17:17"
6262
},
6363
"nodeType": "YulFunctionCall",
64-
"src": "94:24:16"
64+
"src": "94:24:17"
6565
}
6666
],
6767
"functionName": {
6868
"name": "mstore",
6969
"nodeType": "YulIdentifier",
70-
"src": "82:6:16"
70+
"src": "82:6:17"
7171
},
7272
"nodeType": "YulFunctionCall",
73-
"src": "82:37:16"
73+
"src": "82:37:17"
7474
},
7575
"nodeType": "YulExpressionStatement",
76-
"src": "82:37:16"
76+
"src": "82:37:17"
7777
}
7878
]
7979
},
@@ -83,54 +83,54 @@
8383
{
8484
"name": "value",
8585
"nodeType": "YulTypedName",
86-
"src": "60:5:16",
86+
"src": "60:5:17",
8787
"type": ""
8888
},
8989
{
9090
"name": "pos",
9191
"nodeType": "YulTypedName",
92-
"src": "67:3:16",
92+
"src": "67:3:17",
9393
"type": ""
9494
}
9595
],
96-
"src": "7:118:16"
96+
"src": "7:118:17"
9797
},
9898
{
9999
"body": {
100100
"nodeType": "YulBlock",
101-
"src": "229:124:16",
101+
"src": "229:124:17",
102102
"statements": [
103103
{
104104
"nodeType": "YulAssignment",
105-
"src": "239:26:16",
105+
"src": "239:26:17",
106106
"value": {
107107
"arguments": [
108108
{
109109
"name": "headStart",
110110
"nodeType": "YulIdentifier",
111-
"src": "251:9:16"
111+
"src": "251:9:17"
112112
},
113113
{
114114
"kind": "number",
115115
"nodeType": "YulLiteral",
116-
"src": "262:2:16",
116+
"src": "262:2:17",
117117
"type": "",
118118
"value": "32"
119119
}
120120
],
121121
"functionName": {
122122
"name": "add",
123123
"nodeType": "YulIdentifier",
124-
"src": "247:3:16"
124+
"src": "247:3:17"
125125
},
126126
"nodeType": "YulFunctionCall",
127-
"src": "247:18:16"
127+
"src": "247:18:17"
128128
},
129129
"variableNames": [
130130
{
131131
"name": "tail",
132132
"nodeType": "YulIdentifier",
133-
"src": "239:4:16"
133+
"src": "239:4:17"
134134
}
135135
]
136136
},
@@ -140,42 +140,42 @@
140140
{
141141
"name": "value0",
142142
"nodeType": "YulIdentifier",
143-
"src": "319:6:16"
143+
"src": "319:6:17"
144144
},
145145
{
146146
"arguments": [
147147
{
148148
"name": "headStart",
149149
"nodeType": "YulIdentifier",
150-
"src": "332:9:16"
150+
"src": "332:9:17"
151151
},
152152
{
153153
"kind": "number",
154154
"nodeType": "YulLiteral",
155-
"src": "343:1:16",
155+
"src": "343:1:17",
156156
"type": "",
157157
"value": "0"
158158
}
159159
],
160160
"functionName": {
161161
"name": "add",
162162
"nodeType": "YulIdentifier",
163-
"src": "328:3:16"
163+
"src": "328:3:17"
164164
},
165165
"nodeType": "YulFunctionCall",
166-
"src": "328:17:16"
166+
"src": "328:17:17"
167167
}
168168
],
169169
"functionName": {
170170
"name": "abi_encode_t_uint256_to_t_uint256_fromStack",
171171
"nodeType": "YulIdentifier",
172-
"src": "275:43:16"
172+
"src": "275:43:17"
173173
},
174174
"nodeType": "YulFunctionCall",
175-
"src": "275:71:16"
175+
"src": "275:71:17"
176176
},
177177
"nodeType": "YulExpressionStatement",
178-
"src": "275:71:16"
178+
"src": "275:71:17"
179179
}
180180
]
181181
},
@@ -185,44 +185,44 @@
185185
{
186186
"name": "headStart",
187187
"nodeType": "YulTypedName",
188-
"src": "201:9:16",
188+
"src": "201:9:17",
189189
"type": ""
190190
},
191191
{
192192
"name": "value0",
193193
"nodeType": "YulTypedName",
194-
"src": "213:6:16",
194+
"src": "213:6:17",
195195
"type": ""
196196
}
197197
],
198198
"returnVariables": [
199199
{
200200
"name": "tail",
201201
"nodeType": "YulTypedName",
202-
"src": "224:4:16",
202+
"src": "224:4:17",
203203
"type": ""
204204
}
205205
],
206-
"src": "131:222:16"
206+
"src": "131:222:17"
207207
},
208208
{
209209
"body": {
210210
"nodeType": "YulBlock",
211-
"src": "404:32:16",
211+
"src": "404:32:17",
212212
"statements": [
213213
{
214214
"nodeType": "YulAssignment",
215-
"src": "414:16:16",
215+
"src": "414:16:17",
216216
"value": {
217217
"name": "value",
218218
"nodeType": "YulIdentifier",
219-
"src": "425:5:16"
219+
"src": "425:5:17"
220220
},
221221
"variableNames": [
222222
{
223223
"name": "cleaned",
224224
"nodeType": "YulIdentifier",
225-
"src": "414:7:16"
225+
"src": "414:7:17"
226226
}
227227
]
228228
}
@@ -234,24 +234,24 @@
234234
{
235235
"name": "value",
236236
"nodeType": "YulTypedName",
237-
"src": "386:5:16",
237+
"src": "386:5:17",
238238
"type": ""
239239
}
240240
],
241241
"returnVariables": [
242242
{
243243
"name": "cleaned",
244244
"nodeType": "YulTypedName",
245-
"src": "396:7:16",
245+
"src": "396:7:17",
246246
"type": ""
247247
}
248248
],
249-
"src": "359:77:16"
249+
"src": "359:77:17"
250250
}
251251
]
252252
},
253253
"contents": "{\n\n function abi_encode_t_uint256_to_t_uint256_fromStack(value, pos) {\n mstore(pos, cleanup_t_uint256(value))\n }\n\n function abi_encode_tuple_t_uint256__to_t_uint256__fromStack_reversed(headStart , value0) -> tail {\n tail := add(headStart, 32)\n\n abi_encode_t_uint256_to_t_uint256_fromStack(value0, add(headStart, 0))\n\n }\n\n function cleanup_t_uint256(value) -> cleaned {\n cleaned := value\n }\n\n}\n",
254-
"id": 16,
254+
"id": 17,
255255
"language": "Yul",
256256
"name": "#utility.yul"
257257
}
@@ -260,7 +260,7 @@
260260
"linkReferences": {},
261261
"object": "6080604052348015600f57600080fd5b506004361060285760003560e01c806316ada54714602d575b600080fd5b60336047565b604051603e9190605a565b60405180910390f35b60005481565b6054816073565b82525050565b6000602082019050606d6000830184604d565b92915050565b600081905091905056fea26469706673582212200ccb0c54f406c5f94ca07bbe9c717145da8fe82b37b3ee37a813e73d8be65c0564736f6c63430008020033",
262262
"opcodes": "PUSH1 0x80 PUSH1 0x40 MSTORE CALLVALUE DUP1 ISZERO PUSH1 0xF JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x4 CALLDATASIZE LT PUSH1 0x28 JUMPI PUSH1 0x0 CALLDATALOAD PUSH1 0xE0 SHR DUP1 PUSH4 0x16ADA547 EQ PUSH1 0x2D JUMPI JUMPDEST PUSH1 0x0 DUP1 REVERT JUMPDEST PUSH1 0x33 PUSH1 0x47 JUMP JUMPDEST PUSH1 0x40 MLOAD PUSH1 0x3E SWAP2 SWAP1 PUSH1 0x5A JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 RETURN JUMPDEST PUSH1 0x0 SLOAD DUP2 JUMP JUMPDEST PUSH1 0x54 DUP2 PUSH1 0x73 JUMP JUMPDEST DUP3 MSTORE POP POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 ADD SWAP1 POP PUSH1 0x6D PUSH1 0x0 DUP4 ADD DUP5 PUSH1 0x4D JUMP JUMPDEST SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH1 0x0 DUP2 SWAP1 POP SWAP2 SWAP1 POP JUMP INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 0xC 0xCB 0xC SLOAD DELEGATECALL MOD 0xC5 0xF9 0x4C LOG0 PUSH28 0xBE9C717145DA8FE82B37B3EE37A813E73D8BE65C0564736F6C634300 ADDMOD MUL STOP CALLER ",
263-
"sourceMap": "1069:106:5:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1098:16;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;;;;;:::o;7:118:16:-;94:24;112:5;94:24;:::i;:::-;89:3;82:37;72:53;;:::o;131:222::-;;262:2;251:9;247:18;239:26;;275:71;343:1;332:9;328:17;319:6;275:71;:::i;:::-;229:124;;;;:::o;359:77::-;;425:5;414:16;;404:32;;;:::o"
263+
"sourceMap": "1069:106:5:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1098:16;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;;;;;:::o;7:118:17:-;94:24;112:5;94:24;:::i;:::-;89:3;82:37;72:53;;:::o;131:222::-;;262:2;251:9;247:18;239:26;;275:71;343:1;332:9;328:17;319:6;275:71;:::i;:::-;229:124;;;;:::o;359:77::-;;425:5;414:16;;404:32;;;:::o"
264264
}
265265
},
266266
"bytecode": "608060405234801561001057600080fd5b504260008190555060b3806100266000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c806316ada54714602d575b600080fd5b60336047565b604051603e9190605a565b60405180910390f35b60005481565b6054816073565b82525050565b6000602082019050606d6000830184604d565b92915050565b600081905091905056fea26469706673582212200ccb0c54f406c5f94ca07bbe9c717145da8fe82b37b3ee37a813e73d8be65c0564736f6c63430008020033"

ts-tests/build/Contract.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@
66
"linkReferences": {},
77
"object": "6080604052348015600f57600080fd5b50603f80601d6000396000f3fe6080604052600080fdfea264697066735822122006977fabfa6fad9f18e547cefafa048f5053e1fe13432a1739a038e99b0e5bfa64736f6c63430008020033",
88
"opcodes": "PUSH1 0x80 PUSH1 0x40 MSTORE CALLVALUE DUP1 ISZERO PUSH1 0xF JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x3F DUP1 PUSH1 0x1D PUSH1 0x0 CODECOPY PUSH1 0x0 RETURN INVALID PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 MOD SWAP8 PUSH32 0xABFA6FAD9F18E547CEFAFA048F5053E1FE13432A1739A038E99B0E5BFA64736F PUSH13 0x63430008020033000000000000 ",
9-
"sourceMap": "478:20:10:-:0;;;;;;;;;;;;;;;;;;;"
9+
"sourceMap": "478:20:11:-:0;;;;;;;;;;;;;;;;;;;"
1010
},
1111
"deployedBytecode": {
1212
"generatedSources": [],
1313
"immutableReferences": {},
1414
"linkReferences": {},
1515
"object": "6080604052600080fdfea264697066735822122006977fabfa6fad9f18e547cefafa048f5053e1fe13432a1739a038e99b0e5bfa64736f6c63430008020033",
1616
"opcodes": "PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 MOD SWAP8 PUSH32 0xABFA6FAD9F18E547CEFAFA048F5053E1FE13432A1739A038E99B0E5BFA64736F PUSH13 0x63430008020033000000000000 ",
17-
"sourceMap": "478:20:10:-:0;;;;;"
17+
"sourceMap": "478:20:11:-:0;;;;;"
1818
}
1919
},
2020
"bytecode": "6080604052348015600f57600080fd5b50603f80601d6000396000f3fe6080604052600080fdfea264697066735822122006977fabfa6fad9f18e547cefafa048f5053e1fe13432a1739a038e99b0e5bfa64736f6c63430008020033"

0 commit comments

Comments
 (0)