在更新到3.3.0之后,我的测试不想启动。我的Appium在1.4.16.1 (最新版本)中。
我的能力:
def setupTest: AndroidDriver[AndroidElement] = {
val caps: DesiredCapabilities = new DesiredCapabilities
caps.setCapability(CapabilityType.BROWSER_NAME, "")
caps.setCapability("platformName", Setting.platformName)
caps.setCapability("deviceName", Setting.deviceName)
caps.setCapability("platformVersion", Setting.androidVersion.toString)
caps.setCapability("appActivity", Setting.appActivity)
caps.setCapability("app", Setting.pathToApp)
caps.setCapability("unicodeKeyboard", true)
caps.setCapability("resetKeyboard", false)
caps.setCapability("newCommandTimeout", 600)
new AndroidDriver(new URL(Setting.urlToServer), caps)
}我的依赖关系:
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-java</artifactId>
<version>2.48.2</version>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-server</artifactId>
<version>2.48.2</version>
</dependency>
<dependency>
<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>3.3.0</version>
</dependency>但是它不能被编译。控制台日志:
[INFO] C:\Users\medek\workspace\AndroidAppiumTests\src\main\java:-1: info: compiling
[INFO] C:\Users\medek\workspace\AndroidAppiumTests\src\main\scala:-1: info: compiling
[INFO] Compiling 52 source files to C:\Users\medek\workspace\AndroidAppiumTests\target\classes at 1450269109670
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[WARNING] warning: Class org.openqa.selenium.remote.http.HttpClient not found - continuing with a stub.
[ERROR] error: Unable to locate class corresponding to inner class entry for Factory in owner org.openqa.selenium.remote.http.HttpClient
[ERROR] error: Unable to locate class corresponding to inner class entry for Builder in owner org.openqa.selenium.remote.service.DriverService
[WARNING] 8 warnings found
[ERROR] two errors found
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------我在这里和谷歌没有找到任何解决方案。如果我试图降级到java 3.2.0,一切都很好。但在官方文件中,我没有找到任何解决办法。
发布于 2015-12-17 12:00:27
有点棘手。我试图修改java-客户机依赖关系:
<dependency>
<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>LATEST</version>
<exclusions>
<exclusion>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-java</artifactId>
</exclusion>
</exclusions>
</dependency>并删除所有硒依赖项。但我的一个依赖项是我的第二个项目,它也依赖于硒。在第二个项目中,Selenium的旧版本(2.42.2)。所以这两个项目不能一起工作。在将第二个项目更新为Selenium 2.48.2 (最新)之后,一切看起来都很好。
https://stackoverflow.com/questions/34312395
复制相似问题