Skip to content
This repository was archived by the owner on May 23, 2023. It is now read-only.

Commit 0948bb6

Browse files
committed
Add truncated out format handling
Long out values in state tests are encoded by their length instead of the literal value in json.
1 parent bcca152 commit 0948bb6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

.travis.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@ script:
2828
after_success:
2929
- travis_retry pip install coveralls
3030
- cd .tox/$TOX_ENV && coveralls
31-
after_script:
32-
- cat .tox/$TOX_ENV/log/*.log; true
3331
notifications:
3432
slack:
3533
secure: W/UAhQ/GgYwMWrl3aiVAVOWr4WGdWrxUOX/rTB3ZgwDwGqDYLzQO5UqbsQlo1JXPZ6JOWfIPMURhHu7DSfue9dBW6xQ+NL+bFHe9lSXG4nqFK3IjezYyTBzNRJRDbGUvSSqgj6D5cwhJ8BjfUIRPbJz3CxL64KmsNXezEaMY60w=

ethereum/testutils.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -396,6 +396,8 @@ def blkhash(n):
396396
'out', 'gas', 'logs', 'postStateRoot']:
397397
_shouldbe = params1.get(k, None)
398398
_reallyis = params2.get(k, None)
399+
if str_to_bytes(k) == b'out' and _shouldbe[:1] in ('#', b'#'):
400+
_reallyis = str_to_bytes('#%s' % ((len(_reallyis) - 2) // 2))
399401
if _shouldbe != _reallyis:
400402
print(('Mismatch {key}: shouldbe {shouldbe_key} != reallyis {reallyis_key}.\n'
401403
'post: {shouldbe_post} != {reallyis_post}').format(

0 commit comments

Comments
 (0)