-
Notifications
You must be signed in to change notification settings - Fork 242
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Move away from PhantomJS as default? #545
Comments
Yes, for sure. |
I think we should just build out the selenium setup, specifically focusing on chromedriver. |
I second that - on a client's project, the build started failing on CircleCI, I think because PhantomJS was moved to "legacy" (https://circleci.com/docs/2.0/circleci-images/#language-image-variants). I suspect we'll see more of that in the future on other cases. |
For reference, to switch to selenium + chromedriver: # Gemfile
group :test do
gem "selenium-webdriver"
end
# teaspoon_env.rb
Teaspoon.configure do |config|
config.driver = :selenium
config.driver_options = { client_driver: :chrome }
end |
I seem to be caught in a Catch-22 in using Chrome with selenium-webdriver, though. If I have the gem
If I remove the
Has anyone else run into this? Edit: I was wrong above. It isn't actually running my Teaspoon suite in either situation. I also tried this fork to pass in the same Selenium arguments as my Capybara suite gets: |
Has anyone looked into headless browsers? I reference this article and would love feedback on if this is a good direction to go. I am new to Teaspoon, so not sure. https://www.puzzle.ch/de/blog/articles/2018/02/12/phantomjs-is-dead-long-live-headless-browsers As Karma sounded interesting. |
@joshm1204 I think the suggested default approach here would be "Alternative 2" in the article you referenced. |
Yes, I think a chrome's headless browser for example would be a good solution. Is there any ability to use Chrome's headless browser yet? |
@joshm1204 In addition to either using chromedriver-helper gem (deprecated) or webdrivers gem (replacement) and configuring the chromedriver version, you can do something like this inside the config.driver = :selenium
options = ::Selenium::WebDriver::Chrome::Options.new(args: ["--no-sandbox"])
options.headless!
config.driver_options = { client_driver: :chrome, client_driver_opts: { options: options } } |
i'm using a modified version of ^ snippet to, like solidus does at
|
With the PhantomJS project abandoned, and potential issues with teaspoon + phantomjs, should teaspoon change it's default driver to something else?
The text was updated successfully, but these errors were encountered: