Sha256: 4aed6f09f803ec9a1f1413a08fd272a527196d2dd26949b5a72fb7b7e202d254

Contents?: true

Size: 380 Bytes

Versions: 4

Compression:

Stored size: 380 Bytes

Contents

module Serverspec
  module Type
    class Interface < Base
      def speed
        ret = @runner.run_command(commands.get_interface_speed_of(@name))
        val = ret.stdout.strip
        val = val.to_i if val.match(/^\d+$/)
        val
      end

      def has_ipv4_address?(ip_address)
        @runner.check_interface_ipv4_address(@name, ip_address)
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
serverspec-2.0.0.beta12 lib/serverspec/type/interface.rb
serverspec-2.0.0.beta11 lib/serverspec/type/interface.rb
serverspec-2.0.0.beta10 lib/serverspec/type/interface.rb
serverspec-2.0.0.beta9 lib/serverspec/type/interface.rb