Tag: 火焰

如何将selenium html-runner与docker结合使用?

我试图设置一个使用selenium-html-runner的docker镜像来运行从Selenium IDE生成的html文件来自动testing它们。 不过,我在Docker容器中运行Firefox浏览器的GUI非常困难。 我发现了下面的文章( https://medium.com/@yiquanzhou/run-selenium-ui-tests-in-docker-container-78be98e1b52d ),但是在运行命令时不工作: Xvfb :99 -ac & 我打算设置所有必要的configuration,以便我可以运行以下命令: java -Dwebdriver.gecko.driver="/path/to/geckodriver" -jar "path/to/selenium-html-runner.jar" -htmlSuite "*firefox" "https://www.target-website.com" "test_suites/" "results/" 有没有人有以前的经验,在容器内运行selenium-html-runner? 先谢谢你!

无法在Docker容器中打开Firefox

我正试图在Docker容器中运行一个seleniumtesting。 我在Oracle Linux 6.7的基础映像上创build了映像,并在其上安装了firefox 24。 在运行seleniumtesting的入口点脚本中设置Display。 但是,当它运行testing时,它错误地说 [java] org.openqa.selenium.firefox.NotConnectedException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output: [java] *** LOG addons.manager: Application has been upgraded [java] *** LOG addons.xpi: startup [java] *** LOG addons.xpi: Ignoring file entry whose name is not a valid add-on ID: /tmp/anonymous9132988696593276996webdriver-profile/extensions/webdriver-staging [java] *** […]

seleniumtesting与docker或没有

假设我有一些用Selenium WebDriver编写的自动化testing。 据我所知,我可以使用dockerized Firefox浏览器甚至Selenium Grid。 但是我的问题是docker firefox比firefox更好的优点是什么? 在Docker中使用标准Selenium Grid而不使用Docker时,Selenium Grid会出现同样的问题。 谁能告诉我为什么一个比另一个好? 或者在哪些情况下最好在Seleniumtesting中使用docker?

与Selenium集线器和Firefox的Behat错误:无法打开连接:从webdriver收到的有效负载是有效的,但意想不到的json

我正在尝试使用selenium/hub , selenium/node-chrome-debug和selenium/node-firefox-debug图像在Docker上运行Behat。 使用Chrome节点运行Behat正在工作,但Firefox节点给我以下错误: Could not open connection: Payload received from webdriver is valid but unexpected json: {"value":{"sessionId":"244f4715-c59b-4bfc-aa17-8f6a867ead83","capabilities":{"moz:profile":"/tmp/rust_mozprofile.u3mB4xKf6nVD","rotatable":false,"timeouts":{"implicit":0,"pageLoad":300000,"script":30000},"pageLoadStrategy":"normal","moz:headless":false,"moz:accessibilityChecks":false,"acceptInsecureCerts":false,"browserVersion":"57.0","platformVersion":"4.9.60-linuxkit-aufs","moz:processID":1005,"browserName":"firefox","platformName":"linux","moz:webdriverClick":false}}} (Behat\Mink\Exception\DriverException) 当我vnc的Firefox节点,我看到它打开Firefox,但没有发生。 我docker-compose.yml : version: '3.2' services: site.local: image: webdevops/php-apache-dev:7.1 ports: – "8888:80" volumes: – ./public:/app – .:/application selenium-grid-hub.local: image: selenium/hub ports: – "4445:4444" selenium-node-chrome.local: image: selenium/node-chrome-debug environment: – HUB_PORT_4444_TCP_ADDR=selenium-grid-hub.local – HUB_PORT_4444_TCP_PORT=4444 ports: – "5901:5900" selenium-node-firefox.local: image: […]

Docker容器中的Selenium WebDriverException:消息:连接被拒绝

我正在用Selenium + python + firefox做POC,很快我必须用chrometesting一下。 请参考我的github: https : //github.com/jauyzed/selenium-firefox-python 仅供参考:我没有提交所有必需的文件 当我运行容器时,我看到以下错误: Traceback (most recent call last): File "/root/selenium_wd_tests/google_test_ff.py", line 10, in setUp self.driver = webdriver.Firefox() File "/usr/local/lib/python2.7/distpackages/selenium/webdriver/firefox/webdriver.py", line 145, in __init__ keep_alive=True) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 92, in __init__ self.start_session(desired_capabilities, browser_profile) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 179, in start_session response = self.execute(Command.NEW_SESSION, capabilities) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 236, in […]