Sha256: 394075f7dfe01ca9c57848d275193e7fefb3c3895c872176d000dced9f320e9a

Contents?: true

Size: 571 Bytes

Versions: 3

Compression:

Stored size: 571 Bytes

Contents

require 'rails/generators/test_unit'
require 'rails/generators/resource_helpers'

module TestUnit
  module Generators
    class ScaffoldGenerator < Base
      include Rails::Generators::ResourceHelpers

      class_option :singleton, :type => :boolean, :desc => "Supply to create a singleton controller"
      check_class_collision :suffix => "ControllerTest"

      def create_test_files
        template 'functional_test.rb',
                 File.join('test/functional', controller_class_path, "#{controller_file_name}_controller_test.rb")
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
railties-3.0.0.beta4 lib/rails/generators/test_unit/scaffold/scaffold_generator.rb
railties-3.0.0.beta3 lib/rails/generators/test_unit/scaffold/scaffold_generator.rb
railties-3.0.0.beta2 lib/rails/generators/test_unit/scaffold/scaffold_generator.rb