Skip to content

Tag: webdriver

How can we pass in an ExpectedConditions as a parameter to wait.until in Selenium Java?

I’m finding trouble passing in an ExpectedConditions as a parameter in a method to wait.until(). The wait.until() expects a function to be passed in. I am relatively new to Java, and would appreciate the assistance. Offending code: wait.until() expects a function to be passed into it, which looks like ExpectedConditions.urlToBe(“”). I am trying to make a method that could be

why nothing is returned when reading distance displayed on the site mentioned in the body using selenium webdriver

I am trying to read distance value from ‘Distance by Land Transport’ field from the site ( but I am getting nothing though the calculated distance value is displaying in the field. Below is my code and the site used. Questions: why I am getting nothing? ( please see below code String variable: strDist shows nothing) Interestingly, when I

Reach for the deep nested element using Selenium WebDriver (Java)

I looked through a lot of topics on Stackoverflow and tried several recommendations but could hardly succeed in resolving my particular case. I’m trying to automate Google Cloud Pricing Calculator using Selenium WebDriver + Java. I need insert the Number of instances (the first input area on the page) using Java code. My Java code is following: But NoSuchElementException is

JAVA – How to replace string in a binary file (.exe) using regex pattern [closed]

Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 11 months ago. Improve this question I need to read a file named “chromedriver.exe” and replace all the occurrences of a string that starts with “cdc_” and is 26 characters long.