@@ -16,14 +16,14 @@ def generate_request_spec
1616 return unless options [ :request_specs ]
1717
1818 template 'request_spec.rb' ,
19- File . join ( 'spec/ requests', class_path , "#{ file_name } _spec.rb" )
19+ target_path ( ' requests', class_path , "#{ file_name } _spec.rb" )
2020 end
2121
2222 def generate_controller_spec
2323 return unless options [ :controller_specs ]
2424
2525 template 'controller_spec.rb' ,
26- File . join ( 'spec/ controllers', class_path , "#{ file_name } _controller_spec.rb" )
26+ target_path ( ' controllers', class_path , "#{ file_name } _controller_spec.rb" )
2727 end
2828
2929 def generate_view_specs
@@ -35,7 +35,7 @@ def generate_view_specs
3535 actions . each do |action |
3636 @action = action
3737 template 'view_spec.rb' ,
38- File . join ( "spec" , " views" , file_path , "#{ @action } .html.#{ options [ :template_engine ] } _spec.rb" )
38+ target_path ( ' views' , file_path , "#{ @action } .html.#{ options [ :template_engine ] } _spec.rb" )
3939 end
4040 end
4141
@@ -44,7 +44,7 @@ def generate_routing_spec
4444 return unless options [ :routing_specs ]
4545
4646 template 'routing_spec.rb' ,
47- File . join ( 'spec/ routing', class_path , "#{ file_name } _routing_spec.rb" )
47+ target_path ( ' routing', class_path , "#{ file_name } _routing_spec.rb" )
4848 end
4949 end
5050 end
0 commit comments