2

I am trying to add explicit wait in scripting but I am getting the following error

"The type com.google.common.base.Function cannot be resolved. It is indirectly referenced from required .class files"

My code

WebElement okButton; okButton = wait.until(ExpectedConditions.visibilityOfElementLocated(By.xpath("//button[@id='buttonResolveResultOk']"))); 
4
  • who is wait in your code? you need a WebDriverWait there Commented Feb 1, 2018 at 11:21
  • You are missing one of selenium libraries. Do you use maven/gradle? Commented Feb 1, 2018 at 12:31
  • Yes I am using Maven ,I added selenium using <dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-java</artifactId> <version>3.7.1</version> </dependency> Commented Feb 1, 2018 at 13:18
  • I am not sure which jar file is missing , kindly let me know if you have faced this issue earlier Commented Feb 1, 2018 at 13:18

1 Answer 1

3

I updated my guava to latest which helped me to solve this issue

<dependency> <groupId>com.google.guava</groupId> <artifactId>guava</artifactId> <version>21.0</version> </dependency> 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.