Broken selector for `workbench.getTitleBar().getItem("")`
vaclavHala opened this issue · comments
Hi, it seems the method getItem()
on TitleBar
is broken. When called (with parameter 'File'
in this case) I get this error
2023-06-30T16:40:31.504Z INFO webdriver: DATA {using: 'xpath', value: './/div[@aria-label=".//div[@aria-label="File"]"]'}
2023-06-30T16:40:31.543Z WARN webdriver: Request failed with status 400 due to The selector ".//div[@aria-label=".//div[@aria-label="File"]"]" used with strategy "xpath" is invalid! For more information on selectors visit the WebdriverIO docs at: https://webdriver.io/docs/selectors
The selector indeed looks wrong, I'd expect the @aria-label
to contain just "File"
rather than another xpath.
Other methods such as getItem()
on StatusBar
or even getItems()
on TitleBar
itself seem to work fine, only that one method causes trouble.
I'm using wdio-vscode-service
version 5.1.0
Thanks for reporting!
We greatly appreciate any contributions that help resolve the bug. While we understand that active contributors have their own priorities, we kindly request your assistance if you rely on this bug being fixed. We encourage you to take a look at our contribution guidelines or join our friendly Discord development server, where you can ask any questions you may have. Thank you for your support, and cheers!
@christian-bromann here is the fix with tests showing the problem
Let's continue convo in #77