Skip to content

Commit

Permalink
Don't include the path when checking class collisions [#545 state:res…
Browse files Browse the repository at this point in the history
…olved]
  • Loading branch information
josh committed Oct 14, 2008
1 parent c51db4d commit 9ab83b1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions railties/lib/rails_generator/commands.rb
Expand Up @@ -169,6 +169,7 @@ class Create < Base
# Ruby or Rails. In the future, expand to check other namespaces
# such as the rest of the user's app.
def class_collisions(*class_names)
path = class_names.shift
class_names.flatten.each do |class_name|
# Convert to string to allow symbol arguments.
class_name = class_name.to_s
Expand Down
3 changes: 3 additions & 0 deletions railties/test/generators/rails_controller_generator_test.rb
@@ -1,5 +1,8 @@
require 'generators/generator_test_helper'

module Admin
end

class RailsControllerGeneratorTest < GeneratorTestCase

def test_controller_generates_controller
Expand Down

0 comments on commit 9ab83b1

Please sign in to comment.