-
Notifications
You must be signed in to change notification settings - Fork 110
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
Dealing with Webmock #4
Comments
I do not use webmock, but it should let you stub only the internet calls you want? I think it black lists by default, but you can whitelist: I require it in |
Well that sounds simple enough :) Pokes a couple holes in the webmock wall, but I guess as long as you're not testing anything to do with webdrivers, it shouldn't be a problem! I ended up just adding the webdrivers I needed to the image I was using rather than installing them as part of the test run. But this solution certainly seems like it should work 👍 |
For future viewers of this:
|
I ran into this switching from chromedriver-helper to webdrivers. It is a gotcha. If the URLs that webdrivers tries to contact change in the future, of course the Webmock setup would have to be changed too. This is related to #29 The |
`webdrivers` causes an issue with `webmock`. This is therefore a breaking change, and the Readme now has instructions on how to address this. titusfortner/webdrivers#4
`webdrivers` causes an issue with `webmock`. This is therefore a breaking change, and the Readme now has instructions on how to address this. titusfortner/webdrivers#4
`webdrivers` causes an issue with `webmock`. This is therefore a breaking change, and the Readme now has instructions on how to address this. titusfortner/webdrivers#4
- add manifest.js, this is now needed as part of the upgrade to sprockets, see https://github.com/rails/sprockets/blob/master/UPGRADING.md - adjust test helper to allow URL for chromedriver, otherwise tests fail with webmock connect not allowed error, note that if this URL ever changes this file will need to be updated titusfortner/webdrivers#4
- add manifest.js, this is now needed as part of the upgrade to sprockets, see https://github.com/rails/sprockets/blob/master/UPGRADING.md - adjust test helper to allow URL for chromedriver, otherwise tests fail with webmock connect not allowed error, note that if this URL ever changes this file will need to be updated titusfortner/webdrivers#4
- add manifest.js, this is now needed as part of the upgrade to sprockets, see https://github.com/rails/sprockets/blob/master/UPGRADING.md - adjust test helper to allow URL for chromedriver, otherwise tests fail with webmock connect not allowed error, note that if this URL ever changes this file will need to be updated titusfortner/webdrivers#4
I'm using
webmock
in my tests and I can't figure out a good way to deal with it blockingwebdrivers
' requests. I've tried not requiringwebmock
in the gem file, and explicitly requiring it afterwebdrivers
intest_helper.rb
and it still blocks the request... do you have a good method for avoiding this problem?Where do you normally
require 'webdrivers'
? Do you usewebmock
? Is there a command I can call to make it download the drivers immediately so it doesn't get caught after webmock is initialized?The text was updated successfully, but these errors were encountered: