Closed 9dev closed 8 years ago
@9dev we have migrated your subscription to the new build platform. Can you try rerunning your build and if you run into issues, we can take a look.
Thanks!
@manishas Thanks for response. I've rerun my build and I'm still getting the same error:
selenium.common.exceptions.WebDriverException: Message: Can not connect to the Service /usr/bin/google-chrome
@9dev we have a sample project for selenium here https://github.com/shippableSamples/sample_node_selenium
It is currently setup to work with Firefox. I am looking into it to add support for Chrome.
We will reach out to you soon, thanks!
Continuing to work on this today. Hope to get the sample running for chrome soon.
@9dev the sample here https://github.com/pranaypareek/sample_node_selenium/tree/chrome_support should be helpful.
This is a selenium project that uses the drydock/u14nodpls
image for the build which has selenium and the chrome binaries installed on it.
In order to test selenium with a browser, the following commands are required:
- export DISPLAY=:99.0
- xvfb-run --server-args="-ac" npm test
The xvfb-run
command is needed as we do not bring up xvfb as a service.
These commands are specified in the ci
section of the shippable.yml
. You can find the shippable.yml for the sample selenium project here https://github.com/pranaypareek/sample_node_selenium/blob/chrome_support/shippable.yml
The project uses nightwatch.json (http://nightwatchjs.org/) configuration to specify chrome as the browser to be used by selenium for executing the tests against.
The following links might be helpful:
Closing since chrome should work now. @9dev let us know if you run into issues and we'll reopen and investigate.
@manishas @pranaypareek thank you for your work. Unfortunately, I still cannot make it run without errors. Could you tell me where exactly is chromedriver located?
I tried /usr/bin/chromedriver
as your example suggests, but it raises an error "No such file".
browser = webdriver.Chrome('/usr/bin/chromedriver')
My full shippable.yml file:
language: python
python:
- 3.4
services:
- selenium
branches:
only:
- master
build:
pre_ci_boot:
image_name: drydock/u14pytall
image_tag: prod
pull: true
ci:
- mkdir -p shippable/testresults
- DISPLAY=:99.0
- pip install -r requirements.txt
- xvfb-run --server-args="-ac" python manage.py test
Thanks in advance for any tips.
@9dev we missed out on your comment above.
Sorry about that. Re-opening the issue to investigate again.
Please feel free to re-open an issue (or open a new one) in the future if you are facing a problem.
@9dev We have a sample project here. The master
branch runs tests on firefox on the branch testingOnChrome
will test on chrome. Nightwatch.json should be helpful.
@chetantarale Thank you! The key was the correct path to chromedriver.
closing since this works now.
I'd like to use Google Chrome with my Selenium tests. I used code from #285:
but I keep getting the following error:
Is there any working solution for testing with Chrome?