Getting error - Error:(39, 43) java: method until in class org.openqa.selenium.support.ui.FluentWait<T> cannot be applied to given types;
required: java.util.function.Function<? super org.openqa.selenium.WebDriver,V>
found: org.openqa.selenium.support.ui.ExpectedCondition<org.openqa.selenium.WebElement>
reason: cannot infer type-variable(s) V
(argument mismatch; org.openqa.selenium.support.ui.ExpectedCondition<org.openqa.selenium.WebElement> cannot be converted to java.util.function.Function<? super org.openqa.selenium.WebDriver,V>).
These are the dependencies i have in build.gradle file and I am using Java8.
dependencies {
// testCompile 'org.springframework.amqp:spring-amqp:2.0.3.RELEASE'
testCompile 'com.epam.reportportal:commons-model:4.0.3'
testCompile 'com.epam.reportportal:agent-java-testng:4.0.2'
testCompile 'com.epam.reportportal:logger-java-logback:4.0.0'
testCompile 'org.testng:testng:6.14.3'
compile group: 'com.google.guava', name: 'guava', version: '23.0'
compile group: 'org.seleniumhq.selenium', name: 'selenium-java', version: '3.8.1'
//compile group: 'org.seleniumhq.selenium', name: 'selenium-java', version: '3.8.1'
//testCompile 'org.seleniumhq.selenium:selenium-java:3.8.1'
testCompile('com.galenframework:galen-java-support:2.3.3') {
exclude group: 'org.slf4j', module: 'slf4j-simple'
}
testCompile 'org.apache.commons:commons-csv:1.4'
testCompile 'org.apache.commons:commons-lang3:3.3.2'
testCompile 'commons-io:commons-io:2.5'
testCompile 'com.fasterxml.jackson.core:jackson-databind:2.9.7'
testCompile 'com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:2.9.7'
testCompile 'org.jsoup:jsoup:1.7.2'
testCompile 'com.mashape.unirest:unirest-java:1.4.9'
testCompile 'com.sun.mail:javax.mail:1.6.0'
testCompile 'net.jodah:failsafe:1.0.5'
testCompile 'org.mongodb:mongodb-driver:3.6.1'
testCompile 'ch.qos.logback:logback-classic:1.2.3'
testCompile 'com.spireon:platform-cdm-java:1.6.0'
testCompile 'com.spireon:automotive-client:1.8.0'
testCompile 'com.spireon:automotive-cdm-java:1.9.0'
testCompile 'com.spireon:platform-test-utils:0.12'
testCompile 'com.spireon:ubi-test-utils:1.0.0-SNAPSHOT'
testCompile 'com.spireon:automation-utils:1.0.39'
// compile project(':AutomationUtils')
}
Please guide me in resolving this error