Sha256: ddbab0ab295db7ae38b36aca69e7d3200ed4975ba0728dcefcc36055f5249cf0
Contents?: true
Size: 461 Bytes
Versions: 5
Compression:
Stored size: 461 Bytes
Contents
RSpec::Matchers.define :be_reachable do match do |host| proto = 'tcp' timeout = 5 if @attr port = @attr[:port] proto = @attr[:proto] if @attr[:proto] timeout = @attr[:timeout] if @attr[:timeout] end if host.respond_to?(:reachable?) host.reachable?(port, proto, timeout) else backend.check_reachable(host, port, proto, timeout) end end chain :with do |attr| @attr = attr end end
Version data entries
5 entries across 5 versions & 1 rubygems