Skip to content

Fix for #360 #362

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

Closed
wants to merge 1 commit into from
Closed

Fix for #360 #362

wants to merge 1 commit into from

Conversation

be9
Copy link
Contributor

@be9 be9 commented May 3, 2011

No description provided.

Otherwise Capybara's includes are not set correctly.

Fixes rspec#360
begin
require 'webrat'
rescue LoadError
end
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather keep this ^^ in this file. What about just reversing the inclusion order in rails.rb? Also, I'd like a spec for this to avoid regressions. I'm not sure of the best way to manage that yet. Got any ideas?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, inclusion order reversal doesn't work (that's the first thing I tried). BrowserSimulators module is used in Example, so it should be required first.

I'll come up with the spec later, but I still can't see a nicer solution. Load capybara from railtie, tied to a proper initializer?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately this breaks capy support in controller, view, and helper specs. Looks like I'm going to need to rethink how/when capy and webrat get loaded.

@dchelimsky dchelimsky closed this in d0e790e May 4, 2011
@dchelimsky
Copy link
Contributor

I merged your commit, and then made some further changes in ec15a2f.

Let me know if you have any questions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants