Sha256: 5e7728b1c418c51127d1c185503ffb572b2e9ebc943568e84eed7854adccddd8

Contents?: true

Size: 442 Bytes

Versions: 1

Compression:

Stored size: 442 Bytes

Contents

require 'serverspec/type/base'
require 'serverspec/type/service'
require 'serverspec/type/package'
require 'serverspec/type/port'
require 'serverspec/type/file'

module Serverspec
  module Helper
    module Type
      %w( service package port file ).each do |type|
        define_method type do |name|
          self.class.const_get('Serverspec').const_get('Type').const_get(type.capitalize).new(name)
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
serverspec-0.4.1 lib/serverspec/helper/type.rb