mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-12-23 06:48:16 +00:00
client: expected field check fix
This commit is contained in:
parent
c71f234a8b
commit
4e01971e4c
@ -406,7 +406,7 @@ class DebugLinkMixin(object):
|
|||||||
|
|
||||||
for field, value in expected.__dict__.items():
|
for field, value in expected.__dict__.items():
|
||||||
print("EXPECTED", getattr(expected, field), getattr(msg, field), field, value)
|
print("EXPECTED", getattr(expected, field), getattr(msg, field), field, value)
|
||||||
if getattr(expected, field) != value:
|
if getattr(expected, field) is not None and getattr(msg, field) != value:
|
||||||
raise CallException(proto.FailureType.UnexpectedMessage,
|
raise CallException(proto.FailureType.UnexpectedMessage,
|
||||||
"Expected %s, got %s" % (pprint(expected), pprint(msg)))
|
"Expected %s, got %s" % (pprint(expected), pprint(msg)))
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user