mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-12-23 06:48:16 +00:00
device_tests: fix test_msg_recoverydevice for T1
This commit is contained in:
parent
f8f0be9c86
commit
17b37034e8
@ -15,10 +15,9 @@
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public License
|
||||
# along with this library. If not, see <http://www.gnu.org/licenses/>.
|
||||
import pytest
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
from .common import *
|
||||
from .common import TrezorTest
|
||||
from trezorlib import messages as proto
|
||||
|
||||
|
||||
@ -34,6 +33,11 @@ class TestMsgRecoverydevice(TrezorTest):
|
||||
language='english',
|
||||
enforce_wordlist=True))
|
||||
|
||||
# click through confirmation
|
||||
assert isinstance(ret, proto.ButtonRequest)
|
||||
self.client.debug.press_yes()
|
||||
ret = self.client.call_raw(proto.ButtonAck())
|
||||
|
||||
assert isinstance(ret, proto.PinMatrixRequest)
|
||||
|
||||
# Enter PIN for first time
|
||||
@ -92,6 +96,11 @@ class TestMsgRecoverydevice(TrezorTest):
|
||||
language='english',
|
||||
enforce_wordlist=True))
|
||||
|
||||
# click through confirmation
|
||||
assert isinstance(ret, proto.ButtonRequest)
|
||||
self.client.debug.press_yes()
|
||||
ret = self.client.call_raw(proto.ButtonAck())
|
||||
|
||||
fakes = 0
|
||||
for _ in range(int(12 * 2)):
|
||||
assert isinstance(ret, proto.WordRequest)
|
||||
@ -136,6 +145,11 @@ class TestMsgRecoverydevice(TrezorTest):
|
||||
language='english',
|
||||
enforce_wordlist=True))
|
||||
|
||||
# click through confirmation
|
||||
assert isinstance(ret, proto.ButtonRequest)
|
||||
self.client.debug.press_yes()
|
||||
ret = self.client.call_raw(proto.ButtonAck())
|
||||
|
||||
assert isinstance(ret, proto.WordRequest)
|
||||
for _ in range(int(12 * 2)):
|
||||
(word, pos) = self.client.debug.read_recovery_word()
|
||||
@ -154,6 +168,11 @@ class TestMsgRecoverydevice(TrezorTest):
|
||||
language='english',
|
||||
enforce_wordlist=True))
|
||||
|
||||
# click through confirmation
|
||||
assert isinstance(ret, proto.ButtonRequest)
|
||||
self.client.debug.press_yes()
|
||||
ret = self.client.call_raw(proto.ButtonAck())
|
||||
|
||||
assert isinstance(ret, proto.PinMatrixRequest)
|
||||
|
||||
# Enter PIN for first time
|
||||
|
Loading…
Reference in New Issue
Block a user