mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-11-14 11:39:03 +00:00
tests: debug mnemonic is bytes
This commit is contained in:
parent
688d1ac03b
commit
87e6e481fd
@ -29,8 +29,8 @@ class TestDebuglink(TrezorTest):
|
||||
|
||||
def test_mnemonic(self):
|
||||
self.setup_mnemonic_nopin_nopassphrase(lock=False)
|
||||
mnemonic = self.client.debug.state().mnemonic
|
||||
assert mnemonic == self.mnemonic12
|
||||
mnemonic = self.client.debug.state().mnemonic_secret
|
||||
assert mnemonic == self.mnemonic12.encode()
|
||||
|
||||
def test_pin(self):
|
||||
self.setup_mnemonic_pin_passphrase()
|
||||
|
@ -26,7 +26,7 @@ class TestDeviceLoad(TrezorTest):
|
||||
def test_load_device_1(self):
|
||||
self.setup_mnemonic_nopin_nopassphrase(lock=False)
|
||||
state = self.client.debug.state()
|
||||
assert state.mnemonic == self.mnemonic12
|
||||
assert state.mnemonic_secret == self.mnemonic12.encode()
|
||||
assert state.pin is None
|
||||
assert state.passphrase_protection is False
|
||||
|
||||
@ -37,7 +37,7 @@ class TestDeviceLoad(TrezorTest):
|
||||
self.setup_mnemonic_pin_passphrase(lock=False)
|
||||
self.client.set_passphrase("passphrase")
|
||||
state = self.client.debug.state()
|
||||
assert state.mnemonic == self.mnemonic12
|
||||
assert state.mnemonic_secret == self.mnemonic12.encode()
|
||||
assert state.pin == self.pin4
|
||||
assert state.passphrase_protection is True
|
||||
|
||||
|
@ -75,7 +75,7 @@ class TestMsgRecoverydevice(TrezorTest):
|
||||
|
||||
# Mnemonic is the same
|
||||
self.client.init_device()
|
||||
assert self.client.debug.read_mnemonic() == self.mnemonic12
|
||||
assert self.client.debug.read_mnemonic_secret() == self.mnemonic12.encode()
|
||||
|
||||
assert self.client.features.pin_protection is True
|
||||
assert self.client.features.passphrase_protection is True
|
||||
@ -126,7 +126,7 @@ class TestMsgRecoverydevice(TrezorTest):
|
||||
|
||||
# Mnemonic is the same
|
||||
self.client.init_device()
|
||||
assert self.client.debug.read_mnemonic() == self.mnemonic12
|
||||
assert self.client.debug.read_mnemonic_secret() == self.mnemonic12.encode()
|
||||
|
||||
assert self.client.features.pin_protection is False
|
||||
assert self.client.features.passphrase_protection is False
|
||||
|
Loading…
Reference in New Issue
Block a user