You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm unsure if this is related to Browserstack or if it's related to the Safari Browser itself so could I request someone with a MacOS device (I just have Windows machines from Work and personal) to please run this locally on their machine and check if it's working on their machines as well as on a cloud vendor if you have access to one.
I have a weird behaviour I am seeing on Safari where a field that has a Date Value is not being retrieved using getText() whereas the same will work with Chrome
I have saved the code in this repos and it assumes that you have a Browserstack account (potentially it could run on any of the other cloud providers by running the wdio cli install) https://github.com/troyyer/wdiov8browserstackSafariDateField
I have a test to fetch some values from a Salesforce page. when i get the text value for a string value, it comes thru without any issue but when the field has a Date Value, it always comes up as blank
I found a Salesforce preview site to trial this out ( it's a very dirty script with a long wait for the iframes to load)
I have highlighted the 2 fields I am trying to getText() for
in the code I have a console log
console.log(`browser ${browser.capabilities.browserName} this is a text field: `+ await $(`//c-date/div/h2`).getText())
console.log(`browser ${browser.capabilities.browserName} this is a Date field: `+ await $(`//p//lightning-formatted-date-time[1]`).getText())
on Safari the console.log shows the date as blank and the Text field appearing
On chrome this works
I have also trialled with putting in a debug await browser.debug() after the iframes load and trialed selecting the data from the REPL
So depending on someone help with some additional findings, I will raise something either in the WebdriverIO repo or will post it to the Browserstack support
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi there,
I'm unsure if this is related to Browserstack or if it's related to the Safari Browser itself so could I request someone with a MacOS device (I just have Windows machines from Work and personal) to please run this locally on their machine and check if it's working on their machines as well as on a cloud vendor if you have access to one.
I have a weird behaviour I am seeing on Safari where a field that has a Date Value is not being retrieved using
getText()
whereas the same will work with ChromeI have saved the code in this repos and it assumes that you have a Browserstack account (potentially it could run on any of the other cloud providers by running the wdio cli install)
https://github.com/troyyer/wdiov8browserstackSafariDateField
I have a test to fetch some values from a Salesforce page. when i get the text value for a string value, it comes thru without any issue but when the field has a Date Value, it always comes up as blank
I found a Salesforce preview site to trial this out ( it's a very dirty script with a long wait for the iframes to load)
I have highlighted the 2 fields I am trying to
getText()
forin the code I have a console log
on Safari the console.log shows the date as blank and the Text field appearing
On chrome this works
I have also trialled with putting in a debug
await browser.debug()
after the iframes load and trialed selecting the data from the REPLwith Chrome
with Safari
So depending on someone help with some additional findings, I will raise something either in the WebdriverIO repo or will post it to the Browserstack support
Beta Was this translation helpful? Give feedback.
All reactions