aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib/rails_generator/generators/components/integration_test/integration_test_generator.rb
blob: 90fa96938b430d80fcaff5e0cada2fed1c161f15 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
class IntegrationTestGenerator < Rails::Generator::NamedBase
  default_options :skip_migration => false

  def manifest
    record do |m|
      # Check for class naming collisions.
      m.class_collisions class_path, class_name, "#{class_name}Test"

      # integration test directory
      m.directory File.join('test/integration', class_path)

      # integration test stub
      m.template 'integration_test.rb', File.join('test/integration', class_path, "#{file_name}_test.rb")
    end
  end
end