0
디스플레이를 시뮬레이트하기 위해 Xvfb를 사용하여 대나무 서버에서 일부 Selenium 테스트를 실행하려고합니다.셀렌 UnreachableBrowserException
테스트는 ChromeDriver 및 phantomJS와 함께 작동하지만 파이어 폭스와 충돌 :
Forking command line: /bin/sh -c cd /usr/local/bamboo/BAMBOO/xml-data/build-dir/SL-SL-JOB1 && /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java -jar /usr/local/bamboo/BAMBOO/xml-data/build-dir/SL-SL-JOB1/target/surefire/surefirebooter1260921380504465598.jar /usr/local/bamboo/BAMBOO/xml-data/build-dir/SL-SL-JOB1/target/surefire/surefire4923082243141341705tmp /usr/local/bamboo/BAMBOO/xml-data/build-dir/SL-SL-JOB1/target/surefire/surefire_04348841300974089213tmp
Running com.lazerycode.selenium.tests.GoogleExampleIT
Configuring TestNG with: TestNG60Configurator
Current Operating System: LINUX
Current Architecture: amd64
Current Browser Selection: FIREFOX
1495535703540 geckodriver INFO Listening on 127.0.0.1:17068
1495535704705 geckodriver::marionette INFO Starting browser /usr/lib/firefox/firefox.sh with args ["-marionette"]
1495535709415 Marionette INFO Listening on port 39935
1495535709539 Marionette WARN TLS certificate errors will be ignored for this session
mai 23, 2017 12:35:10 PM org.openqa.selenium.remote.ProtocolHandshake createSession
INFOS: Detected dialect: W3C
mai 23, 2017 12:35:12 PM org.openqa.selenium.os.UnixProcess destroy
INFOS: Command failed to close cleanly. Destroying forcefully (v2). [/usr/local/bamboo/BAMBOO/xml-data/build-dir/SL-SL-JOB1/src/test/resources/selenium_standalone_binaries/linux/marionette/64bit/geckodriver, --port=17068][ {}]
mai 23, 2017 12:35:13 PM org.openqa.selenium.os.UnixProcess destroy
GRAVE: Unable to kill process with PID 4042
Tests run: 5, Failures: 2, Errors: 0, Skipped: 3, Time elapsed: 11.775 sec <<< FAILURE! - in com.lazerycode.selenium.tests.GoogleExampleIT
setup(com.lazerycode.selenium.tests.GoogleExampleIT) Time elapsed: 11.021 sec <<< FAILURE!
org.openqa.selenium.remote.UnreachableBrowserException:
Error communicating with the remote browser. It may have died.
Build info: version: '3.4.0', revision: 'unknown', time: 'unknown'
System info: host: 'vps409374', ip: '127.0.1.1', os.name: 'Linux', os.arch: 'amd64', os.version: '4.4.0-78-generic', java.version: '1.8.0_131'
Driver info: driver.version: RemoteWebDriver
Capabilities [{moz:profile=/tmp/rust_mozprofile.3cTlgJI5I9iE, rotatable=false, timeouts={implicit=0.0, pageLoad=300000.0, script=30000.0}, pageLoadStrategy=normal, platform=ANY, specificationLevel=0.0, moz:accessibilityChecks=false, acceptInsecureCerts=true, browserVersion=53.0.2, platformVersion=4.4.0-78-generic, moz:processID=4050.0, browserName=firefox, javascriptEnabled=true, platformName=linux}]
Session ID: 329b5087-5597-478b-9dac-6472c5490aee
at com.lazerycode.selenium.tests.GoogleExampleIT.setup(GoogleExampleIT.java:21)
Caused by: org.apache.http.conn.HttpHostConnectException: Connect to localhost:17068 [localhost/127.0.0.1] failed: Connection refused (Connection refused)
at com.lazerycode.selenium.tests.GoogleExampleIT.setup(GoogleExampleIT.java:21)
Caused by: java.net.ConnectException: Connection refused (Connection refused)
at com.lazerycode.selenium.tests.GoogleExampleIT.setup(GoogleExampleIT.java:21)
closeDriverObjects(com.lazerycode.selenium.tests.GoogleExampleIT) Time elapsed: 11.605 sec <<< FAILURE!
org.openqa.selenium.remote.UnreachableBrowserException:
Error communicating with the remote browser. It may have died.
Build info: version: '3.4.0', revision: 'unknown', time: 'unknown'
System info: host: 'vps409374', ip: '127.0.1.1', os.name: 'Linux', os.arch: 'amd64', os.version: '4.4.0-78-generic', java.version: '1.8.0_131'
Driver info: driver.version: RemoteWebDriver
Capabilities [{moz:profile=/tmp/rust_mozprofile.3cTlgJI5I9iE, rotatable=false, timeouts={implicit=0.0, pageLoad=300000.0, script=30000.0}, pageLoadStrategy=normal, platform=ANY, specificationLevel=0.0, moz:accessibilityChecks=false, acceptInsecureCerts=true, browserVersion=53.0.2, platformVersion=4.4.0-78-generic, moz:processID=4050.0, browserName=firefox, javascriptEnabled=true, platformName=linux}]
Session ID: 329b5087-5597-478b-9dac-6472c5490aee
Caused by: org.apache.http.conn.HttpHostConnectException: Connect to localhost:17068 [localhost/127.0.0.1] failed: Connection refused (Connection refused)
Caused by: java.net.ConnectException: Connection refused (Connection refused)
Results :
Failed tests:
GoogleExampleIT>DriverBase.closeDriverObjects:43 » UnreachableBrowser Error co...
GoogleExampleIT.setup:21 » UnreachableBrowser Error communicating with the rem...
Tests run: 5, Failures: 2, Errors: 0, Skipped: 3
당신은 github에 여기에 모든 테스트 코드를 찾을 수 있습니다 : https://github.com/Joel-Costamagna/Selenium-Maven-Template
호환되는지 어떻게 확인할 수 있습니까? 최신 버전을 사용하기 위해 프로젝트를 업데이트했지만 오류가 계속 발생합니다. –
firefox 및 geckodrivers의 differents 버전을 사용해 보았지만 문제가 해결되지 않았습니다. –