class TestUnit::Generators::ComponentGenerator

Public Instance Methods

create_test_file() click to toggle source
# File lib/rails/generators/test_unit/component_generator.rb, line 9
def create_test_file
  template "component_test.rb", File.join("test/components", class_path, "#{file_name}_component_test.rb")
end

Private Instance Methods

file_name() click to toggle source
Calls superclass method
# File lib/rails/generators/test_unit/component_generator.rb, line 15
def file_name
  @_file_name ||= super.sub(/_component\z/i, "")
end