Sha256: fbbefb52beb277023a4e097062dfc975f4330f0029e719b1e0a241b9fcbab380

Contents?: true

Size: 494 Bytes

Versions: 2

Compression:

Stored size: 494 Bytes

Contents

require_relative "command_generator"

module Foobara
  module Generators
    module CommandGenerator
      module Generators
        class CommandSpecGenerator < CommandGenerator
          def template_path
            ["spec", "command_spec.rb.erb"]
          end

          def target_path
            *path, file = module_path.map { |part| Util.underscore(part) }

            file = "#{file}_spec.rb"

            ["spec", *path, file]
          end
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
foobara-command-generator-0.0.2 src/command_spec_generator.rb
foobara-command-generator-0.0.1 src/command_spec_generator.rb