Permalink
Browse files

Use global namespace Rails

  • Loading branch information...
1 parent 1186293 commit 4686ace999467935e659260d1a23c6617bc51986 Stefan Sprenger committed May 26, 2011
View
2 railties/lib/rails/generators/rails/plugin_new/templates/lib/%name%/engine.rb
@@ -1,5 +1,5 @@
module <%= camelized %>
- class Engine < Rails::Engine
+ class Engine < ::Rails::Engine
<% if mountable? -%>
isolate_namespace <%= camelized %>
<% end -%>
View
2 railties/test/generators/plugin_new_generator_test.rb
@@ -148,7 +148,7 @@ def test_creating_engine_in_full_mode
assert_file "app/views"
assert_file "app/helpers"
assert_file "config/routes.rb", /Rails.application.routes.draw do/
- assert_file "lib/bukkits/engine.rb", /module Bukkits\n class Engine < Rails::Engine\n end\nend/
+ assert_file "lib/bukkits/engine.rb", /module Bukkits\n class Engine < ::Rails::Engine\n end\nend/
assert_file "lib/bukkits.rb", /require "bukkits\/engine"/
end

0 comments on commit 4686ace

Please sign in to comment.