Skip to content
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

Restore respond_to? check for default_url_options #2277

Merged
merged 1 commit into from Feb 10, 2020

Commits on Feb 9, 2020

  1. Restore respond_to? check for default_url_options

    Reverts part of d52a135.
    
    Feature example groups usually have a `default_url_options` class
    attribute, but it's not added if the method is already defined:
    
    https://github.com/rails/rails/blob/v6.0.2.1/actionpack/lib/action_dispatch/routing/url_for.rb#L92
    
    Request example groups have a `default_url_options` instance method:
    
    https://github.com/rails/rails/blob/v6.0.2.1/actionpack/lib/action_dispatch/testing/integration.rb#L388
    
    This means that when a feature example group is defined inside a request
    example group, it will only have the instance method, and trying to call
    `default_url_options` on the example group will fail.
    eugeneius committed Feb 9, 2020
    Configuration menu
    Copy the full SHA
    94c43d9 View commit details
    Browse the repository at this point in the history