BigW Consortium Gitlab

Commit e3d2304d by Robert Speicher

Specs don't need to set default_url_options anymore

parent 2c905797
require 'spec_helper'
feature 'Users' do
around do |ex|
old_url_options = Rails.application.routes.default_url_options
Rails.application.routes.default_url_options = { host: 'example.foo' }
ex.run
Rails.application.routes.default_url_options = old_url_options
end
scenario 'GET /users/sign_in creates a new user account' do
visit new_user_session_path
fill_in 'user_name', with: 'Name Surname'
......
......@@ -4,17 +4,6 @@
module ReferenceFilterSpecHelper
extend ActiveSupport::Concern
included do
before { set_default_url_options }
end
# Allow *_url helpers to work
def set_default_url_options
Rails.application.routes.default_url_options = {
host: 'example.foo'
}
end
# Shortcut to Rails' auto-generated routes helpers, to avoid including the
# module
def urls
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment