From 7ae88942142fb1e9a1e6b3e5a84e652a75efa6cd Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Fri, 11 Apr 2014 15:17:36 +0200 Subject: [PATCH] fix two more unit tests --- tests/test_protection_levels.py | 2 +- tests/test_zerosig.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test_protection_levels.py b/tests/test_protection_levels.py index bb550acd6..14242de47 100644 --- a/tests/test_protection_levels.py +++ b/tests/test_protection_levels.py @@ -150,7 +150,7 @@ class TestProtectionLevels(common.TrezorTest): proto.PassphraseRequest(), proto.ButtonRequest(code=proto_types.ButtonRequest_ConfirmOutput), proto.ButtonRequest(code=proto_types.ButtonRequest_SignTx), - proto.TxRequest(finished=True)]) + proto.TxRequest(request_type=proto_types.TXFINISHED)]) self.client.simple_sign_tx('Bitcoin', [inp1, ], [out1, ]) # def test_firmware_erase(self): diff --git a/tests/test_zerosig.py b/tests/test_zerosig.py index 15fa04778..937d7ba69 100644 --- a/tests/test_zerosig.py +++ b/tests/test_zerosig.py @@ -56,8 +56,8 @@ class TestZeroSig(common.TrezorTest): ) msg = self.client._prepare_simple_sign_tx('Bitcoin', [inp1], [out1]) - tx = self.client.call(msg) - siglen = ord(tx.serialized_tx[44]) + tx = self.client.call(msg) + siglen = ord(tx.serialized.serialized_tx[44]) # Trezor must strip leading zero from signature self.assertEqual(siglen, 67) @@ -79,7 +79,7 @@ class TestZeroSig(common.TrezorTest): msg = self.client._prepare_simple_sign_tx('Bitcoin', [inp1], [out1]) tx = self.client.call(msg) - siglen = ord(tx.serialized_tx[44]) + siglen = ord(tx.serialized.serialized_tx[44]) # Trezor must strip leading zero from signature self.assertEqual(siglen, 66)