Skip to content

Commit 3ef47f7

Browse files
authored
Merge pull request #46 from lugi0/menu-locator
Add suffix to menu items locator
2 parents 6e8d23a + 233fe8a commit 3ef47f7

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

src/JupyterLibrary/clients/jupyterlab/Selectors.resource

+3
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,10 @@ ${JLAB TEXT BUSY PROMPT} In [*]:
2727
${JLAB XP LAUNCHER} //div[contains(@class, 'jp-Launcher-body')]
2828
${JLAB XP CARD} //div[contains(@class, 'jp-LauncherCard')]
2929
${JLAB XP DOCK} //div[@id='jp-main-dock-panel']
30+
${JLAB XP MENU ITEM} //li[contains(@class, 'p-Menu-item')]
3031
${JLAB XP MENU ITEM LABEL} //div[contains(@class, 'p-Menu-itemLabel')]
32+
${JLAB XP MENU ITEM ENABLED} ${JLAB XP MENU ITEM}\[not(contains(@class,'p-mod-disabled'))]
33+
${JLAB XP MENU ITEM LABEL ENABLED} ${JLAB XP MENU ITEM ENABLED}/div[contains(@class, 'p-Menu-itemLabel')]
3134
${JLAB XP MENU LABEL} //div[contains(@class, 'p-MenuBar-itemLabel')]
3235
${JLAB XP TOP} //div[@id='jp-top-panel']
3336
${JLAB XP MAIN AREA FRAG} [contains(@class, 'jp-MainAreaWidget')]

src/JupyterLibrary/clients/jupyterlab/Shell.resource

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Click JupyterLab Menu
4646
Click JupyterLab Menu Item
4747
[Documentation] Click a currently-visible JupyterLab menu item by ``label``.
4848
[Arguments] ${label}
49-
${item} = Set Variable ${JLAB XP MENU ITEM LABEL}\[text() = '${label}']
49+
${item} = Set Variable ${JLAB XP MENU ITEM LABEL ENABLED}\[text() = '${label}']
5050
Wait Until Page Contains Element ${item}
5151
Mouse Over ${item}
5252
Click Element ${item}

0 commit comments

Comments
 (0)