Sha256: 27751abb7f9bef9f6b57acb8717860f6f7655b80c19bcf838b1f20754f0efbe8

Contents?: true

Size: 380 Bytes

Versions: 5

Compression:

Stored size: 380 Bytes

Contents

module TestUnit
  module Generators
    class DecoratorGenerator < ::Rails::Generators::NamedBase
      source_root File.expand_path("templates", __dir__)
      check_class_collision suffix: "DecoratorTest"

      def create_test_file
        template 'decorator_test.rb', File.join('test/decorators', class_path, "#{singular_name}_decorator_test.rb")
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
draper-4.0.2 lib/generators/test_unit/decorator_generator.rb
draper-4.0.1 lib/generators/test_unit/decorator_generator.rb
draper-4.0.0 lib/generators/test_unit/decorator_generator.rb
draper-3.1.0 lib/generators/test_unit/decorator_generator.rb
draper-3.0.1 lib/generators/test_unit/decorator_generator.rb