Sha256: 1433cb4a744c2d1a9e76b24a9b7b11b62cd3c24880576b1598475cc60c87ba1d

Contents?: true

Size: 647 Bytes

Versions: 2

Compression:

Stored size: 647 Bytes

Contents

require 'rails/generators'
module Tsuite
  class InstallGenerator < Rails::Generators::Base
    desc "Add the rspec \"spec\" and cucumber \"features\" folders, plus support for @poltergeist"

    def self.source_root
      @source_root ||= File.join(File.dirname(__FILE__), 'templates')
    end

    # Can add command line options defined like Thor:
#    class_option :extra, :desc => "Add extra stuff", :type => :boolean, :default => false
    # Reference these options later with options[:my_opt]
    def install
      generate "rspec:install"
      generate "cucumber:install"
      template 'features/support/poltergeist.rb'
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
tsuite-0.1.6 lib/generators/tsuite/install_generator.rb
tsuite-0.1.5 lib/generators/tsuite/install_generator.rb