1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-18 20:38:10 +00:00

fix(tests): button content comparison

[no changelog]
This commit is contained in:
obrusvit 2024-04-28 20:28:51 +02:00 committed by Vít Obrusník
parent fccfa43ac9
commit b24e044499
2 changed files with 3 additions and 3 deletions

View File

@ -70,7 +70,7 @@ def _check_ping_screen_texts(client: Client, title: str, right_button: str) -> N
yield
layout = client.debug.wait_layout()
assert layout.title().upper() == title.upper()
assert layout.button_contents()[-1] == right_button.upper()
assert layout.button_contents()[-1].upper() == right_button.upper()
client.debug.press_yes()
# TT does not have a right button text (but a green OK tick)

View File

@ -42,7 +42,7 @@ def test_abort(core_emulator: Emulator):
device_handler.run(device.recover, pin_protection=False)
assert debug.wait_layout().title() == "RECOVER WALLET"
assert debug.wait_layout().title().lower() == "recover wallet"
layout = debug.click(buttons.OK, wait=True)
assert "number of words" in layout.text_content()
@ -61,7 +61,7 @@ def test_abort(core_emulator: Emulator):
assert "Enter your backup" in debug.read_layout().text_content()
layout = debug.click(buttons.CANCEL, wait=True)
assert layout.title() in ("ABORT RECOVERY", "CANCEL RECOVERY")
assert layout.title().lower() in ("abort recovery", "cancel recovery")
layout = debug.click(buttons.OK, wait=True)
assert layout.main_component() == "Homescreen"