Sha256: 638bf0e291ea1fc528756d681b41f914d3bc489db4aa625f8a4fdfb8d6187176

Contents?: true

Size: 363 Bytes

Versions: 5

Compression:

Stored size: 363 Bytes

Contents

require 'generators/rspec'

module Rspec
  module Generators
    class HelperGenerator < Base
      class_option :helpers, :type => :boolean, :default => true

      def create_helper_files
        return unless options[:helpers]

        template 'helper_spec.rb', File.join('spec/helpers', class_path, "#{file_name}_helper_spec.rb")
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
rspec-rails-2.0.0.beta.22 lib/generators/rspec/helper/helper_generator.rb
rspec-rails-2.0.0.beta.20 lib/generators/rspec/helper/helper_generator.rb
rspec-rails-2.0.0.beta.19 lib/generators/rspec/helper/helper_generator.rb
rspec-rails-2.0.0.beta.18 lib/generators/rspec/helper/helper_generator.rb
rspec-rails-2.0.0.beta.17 lib/generators/rspec/helper/helper_generator.rb