Skip to content

Commit e0bd914

Browse files
authored
fix(tests): fix unit tests and use Bytecode verbatim (ethereum#1137)
1 parent e657916 commit e0bd914

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

osaka/eip7692_eof_v1/eip4750_functions/test_code_validation.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def test_eof_validity(
190190
name="imm1",
191191
sections=[
192192
Section.Code(
193-
code=Op.CALLF + Op.STOP,
193+
code=Op.CALLF + b"\x00",
194194
)
195195
],
196196
),
@@ -201,7 +201,7 @@ def test_eof_validity(
201201
code=Op.PUSH0 + Op.PUSH0 + Op.CALLF[1] + Op.STOP,
202202
),
203203
Section.Code(
204-
code=Op.CALLF + Op.STOP, # would be valid with "02" + Op.RETF.
204+
code=Op.CALLF + b"\x00", # would be valid with "02" + Op.RETF.
205205
code_inputs=2,
206206
code_outputs=1,
207207
max_stack_height=2,

osaka/eip7692_eof_v1/eip7480_data_section/test_code_validation.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ def test_legacy_initcode_invalid_eof_v1_contract(
192192
Container(
193193
name="imm1",
194194
sections=[
195-
Section.Code(Op.DATALOADN + Op.STOP),
195+
Section.Code(Op.DATALOADN + b"\x00"),
196196
Section.Data(b"\xff" * 32),
197197
],
198198
),
@@ -204,7 +204,7 @@ def test_legacy_initcode_invalid_eof_v1_contract(
204204
max_stack_height=1,
205205
),
206206
Section.Code(
207-
Op.DATALOADN + Op.STOP,
207+
Op.DATALOADN + b"\x00",
208208
code_outputs=1,
209209
),
210210
Section.Code(

0 commit comments

Comments
 (0)