@@ -41,22 +41,6 @@ def self.initialize_configuration(config)
41
41
config . backtrace_exclusion_patterns << /vendor\/ /
42
42
config . backtrace_exclusion_patterns << %r{ lib/rspec/rails }
43
43
44
- config . include RSpec ::Rails ::ControllerExampleGroup , :type => :controller
45
- config . include RSpec ::Rails ::HelperExampleGroup , :type => :helper
46
- config . include RSpec ::Rails ::ModelExampleGroup , :type => :model
47
- config . include RSpec ::Rails ::RequestExampleGroup , :type => :request
48
- config . include RSpec ::Rails ::RoutingExampleGroup , :type => :routing
49
- config . include RSpec ::Rails ::ViewExampleGroup , :type => :view
50
- config . include RSpec ::Rails ::FeatureExampleGroup , :type => :feature
51
-
52
- if defined? ( ActionMailer )
53
- config . include RSpec ::Rails ::MailerExampleGroup , :type => :mailer
54
- end
55
-
56
- if defined? ( ActiveJob )
57
- config . include RSpec ::Rails ::JobExampleGroup , :type => :job
58
- end
59
-
60
44
# controller settings
61
45
config . add_setting :infer_base_class_for_anonymous_controllers , :default => true
62
46
@@ -106,6 +90,22 @@ def infer_spec_type_from_file_location!
106
90
end
107
91
end
108
92
end
93
+
94
+ config . include RSpec ::Rails ::ControllerExampleGroup , :type => :controller
95
+ config . include RSpec ::Rails ::HelperExampleGroup , :type => :helper
96
+ config . include RSpec ::Rails ::ModelExampleGroup , :type => :model
97
+ config . include RSpec ::Rails ::RequestExampleGroup , :type => :request
98
+ config . include RSpec ::Rails ::RoutingExampleGroup , :type => :routing
99
+ config . include RSpec ::Rails ::ViewExampleGroup , :type => :view
100
+ config . include RSpec ::Rails ::FeatureExampleGroup , :type => :feature
101
+
102
+ if defined? ( ActionMailer )
103
+ config . include RSpec ::Rails ::MailerExampleGroup , :type => :mailer
104
+ end
105
+
106
+ if defined? ( ActiveJob )
107
+ config . include RSpec ::Rails ::JobExampleGroup , :type => :job
108
+ end
109
109
end
110
110
111
111
initialize_configuration RSpec . configuration
0 commit comments