Sha256: 93722f1c6e1ca9c3efd1c4b5ee7eb27c34231290ba975db588777563a6fbbcdc
Contents?: true
Size: 662 Bytes
Versions: 1
Compression:
Stored size: 662 Bytes
Contents
class FeatureGenerator < RubiGen::Base attr_reader :plural_name, :singular_name, :class_name def initialize(runtime_args, runtime_options = {}) super usage if args.empty? @name = args.shift @plural_name = @name.pluralize @singular_name = @name.singularize @class_name = @name.classify end def manifest record do |m| m.directory 'features/steps' m.template 'feature.erb', "features/manage_#{plural_name}.feature" m.template 'steps.erb', "features/steps/#{singular_name}_steps.rb" end end protected def banner "Usage: #{$0} feature ModelName [feature1] [feature2]" end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
newgem-0.28.0 | cucumber_generators/feature/feature_generator.rb |