获取以下错误消息
Cannot resolve method 'in(Java.util.concurrent.TimeUnit)'
使用下面的代码片段,在java类中说A
getImplicitWaitTimeout().in(TimeUnit.SECONDS)
A类使用的Java类方法
private Duration waitForElementTimeout;
public Duration getImplicitWaitTimeout() {
if (this.waitForElementTimeout == null) {
int configuredWaitForTimeoutInMilliseconds = ThucydidesSystemProperty.WEBDRIVER_TIMEOUTS_IMPLICITLYWAIT.integerFrom(this.environmentVariables, (int)DefaultTimeouts.DEFAULT_IMPLICIT_WAIT_TIMEOUT.toMillis());
this.waitForElementTimeout = Duration.ofMillis((long)configuredWaitForTimeoutInMilliseconds);
}
return this.waitForElementTimeout;
}
这与Java 8有关吗?
温温酱
相关分类