Rename chromedriver so it does not conflict with system installed #58
Conversation
Hi, Thanks for submitting this proposed change. This is a breaking change. Part of the value of I'm assuming this is related to the discussion happening at #57 and so I'd like to continue the conversation there about possible ways to address that underlying problem, before we consider making a significant breaking change of this nature. Hope that all makes sense! |
@flavorjones sure this is a possible and working solution to the problem, and sure it's a somewhat breaking change so increasing major version would be suggested. |
Reopened because of conversation at #57. Will re-examine my assumptions. |
I'd like to play with some upgrade scenarios before merging. Should be able to do that today. |
Scenarios to test:
|
Then actions to take:
(I considered renaming |
This will be in a v2.0.0 release shortly. I've bumped the major version because of the backwards incompatibility (Some people may have scripts? I honestly don't know.) |
The bin shim provides by `chromedriver-helper` gem has renamed to `chromedriver-helper` since 2.0. flavorjones/chromedriver-helper#58 Since bin of new name is set to driver path in `lib/chromedriver-helper.rb`, need to load it.
I'm seeing this error: unable to connect to chromedriver 127.0.0.1:9515 (Selenium::WebDriver::Error::WebDriverError) PR flavorjones#58 changes the "chromedriver" executable file name to "chromedriver-helper", but I found that Selenium::WebDriver::Chrome.driver_path was nil after trying to visit a page (after rescuing from the failure). The problem is that I was never loading the new chromedriver-helper code to set the custom driver_path. I added this to features/support/env.rb and my Cucumber scenario started working: require 'chromedriver-helper' I'm using this outside of Rails in a standalone test suite to test an app that is developed separately. (Rails may be requiring the gem behind the scenes.) Mention the possible need to require 'chromedriver-helper' in the Standalone section of the README, where people will be looking for installation instructions.
I'm seeing this error: unable to connect to chromedriver 127.0.0.1:9515 (Selenium::WebDriver::Error::WebDriverError) PR flavorjones#58 changes the "chromedriver" executable file name to "chromedriver-helper", but I found that Selenium::WebDriver::Chrome.driver_path was nil after trying to visit a page (after rescuing from the failure). The problem is that I was never loading the new chromedriver-helper code to set the custom driver_path. I added this to features/support/env.rb and my Cucumber scenario started working: require "chromedriver-helper" I'm using this outside of Rails in a standalone test suite to test an app that is developed separately. (Rails may be requiring the gem behind the scenes.) Mention the possible need to require "chromedriver-helper" in the Standalone section of the README, where people will be looking for installation instructions.
Fixes: #57
Rename the bin shim from
chromedriver
tochromedriver-helper
so it doesn't shadows system installed one (which can break projects not usingchromedriver-helper
)Seems to work fine with a new default rails 5.2.1 project. Assumes the project is using
Selenium::WebDriver
and that it's required before (we could be issuing and user friendly message if this is not the case)