部分地在Selenium RC testing with Maven回答的問題 - 基本上說回到使用Firefox 3.5(但一個答案表明不起作用)。反正也不是一個選項 - 我們正在使用3.6.8。如何讓Maven在Firefox 3.6中運行Selenium測試?
無論如何,關於如何讓Maven/Selenium與Firefox 3.6.x一起工作的任何線索?
我試圖使用方法:
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium</artifactId>
<version>2.0a5</version>
</dependency>
對於在測試中使用相關的Java類。
和:
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>selenium-maven-plugin</artifactId>
<version>1.1-SNAPSHOT</version>
<executions>
<execution>
<phase>pre-integration-test</phase>
<goals>
<goal>start-server</goal>
</goals>
<configuration>
<background>true</background>
</configuration>
</execution>
<execution>
<id>stop-selenium</id>
<phase>post-integration-test</phase>
<goals>
<goal>stop-server</goal>
</goals>
</execution>
</executions>
</plugin>
當我運行鍼對Firefox的集成測試,我得到:
INFO [org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher]準備的Firefox配置文件...
錯誤[org.openqa.selenium.server.BrowserSessionFactory]無法啓動新瀏覽器會話,關閉瀏覽器並清除所有會話數據 java.lang.RuntimeException:在準備配置文件時Firefox拒絕關機
造成者: org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher $ FileLockRemainedException:鎖定文件仍然存在! C:\ DOCUME〜1 \ XXX \ LOCALS在org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.waitForFileLockToGoAway(FirefoxChromeLauncher.java:269)〜1個\ TEMP \ customProfileDirb809d85d6d064be0bdd1a4ee68035cbb \ parent.lock
這是Selenium 2.0b3的問題嗎? – Ardesco 2011-05-26 09:57:11