1
- from ragger . firmware import Firmware
1
+ from ledgered . devices import Device , DeviceType
2
2
from ragger .navigator import Navigator , NavInsID , NavIns
3
3
4
4
5
5
# In this test we check the behavior of the device main menu
6
- def test_app_mainmenu (firmware : Firmware ,
6
+ def test_app_mainmenu (device : Device ,
7
7
navigator : Navigator ,
8
8
test_name : str ,
9
9
default_screenshot_path : str ) -> None :
10
10
# Navigate in the main menu
11
11
instructions = []
12
- if firmware .is_nano :
12
+ if device .is_nano :
13
13
instructions += [
14
14
NavInsID .RIGHT_CLICK ,
15
15
NavInsID .BOTH_CLICK ,
@@ -28,7 +28,7 @@ def test_app_mainmenu(firmware: Firmware,
28
28
NavInsID .BOTH_CLICK ,
29
29
NavInsID .RIGHT_CLICK ,
30
30
]
31
- elif firmware is Firmware .STAX :
31
+ elif device . type == DeviceType .STAX :
32
32
instructions += [
33
33
NavInsID .USE_CASE_HOME_SETTINGS ,
34
34
NavIns (NavInsID .TOUCH , (200 , 113 )),
@@ -38,7 +38,7 @@ def test_app_mainmenu(firmware: Firmware,
38
38
NavInsID .USE_CASE_SETTINGS_NEXT ,
39
39
NavInsID .USE_CASE_SETTINGS_MULTI_PAGE_EXIT
40
40
]
41
- elif firmware is Firmware .FLEX :
41
+ elif device . type is DeviceType .FLEX :
42
42
instructions += [
43
43
NavInsID .USE_CASE_HOME_SETTINGS ,
44
44
NavIns (NavInsID .TOUCH , (200 , 113 )),
0 commit comments