aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/generators/generators_test_helper.rb
diff options
context:
space:
mode:
authorJosé Valim <jose.valim@gmail.com>2010-03-19 18:11:37 +0100
committerJosé Valim <jose.valim@gmail.com>2010-03-19 18:12:54 +0100
commit562154fcbc8f36f94c986a3253c73ae88e2c1146 (patch)
tree69f03eef669c16786dc71385decacfa6e856a06c /railties/test/generators/generators_test_helper.rb
parent541194f641c960efe739b16f76999f47742d12ba (diff)
downloadrails-562154fcbc8f36f94c986a3253c73ae88e2c1146.tar.gz
rails-562154fcbc8f36f94c986a3253c73ae88e2c1146.tar.bz2
rails-562154fcbc8f36f94c986a3253c73ae88e2c1146.zip
Controller generator now creates routes as well [#4233 state:resolved]
Diffstat (limited to 'railties/test/generators/generators_test_helper.rb')
-rw-r--r--railties/test/generators/generators_test_helper.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/railties/test/generators/generators_test_helper.rb b/railties/test/generators/generators_test_helper.rb
index 32be99b144..9e56b3732f 100644
--- a/railties/test/generators/generators_test_helper.rb
+++ b/railties/test/generators/generators_test_helper.rb
@@ -26,4 +26,11 @@ module GeneratorsTestHelper
end
end
end
+
+ def copy_routes
+ routes = File.expand_path("../../../lib/generators/rails/app/templates/config/routes.rb", __FILE__)
+ destination = File.join(destination_root, "config")
+ FileUtils.mkdir_p(destination)
+ FileUtils.cp File.expand_path(routes), destination
+ end
end \ No newline at end of file