diff options
author | Eric Wong <normalperson@yhbt.net> | 2011-03-01 16:36:44 -0800 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2011-03-01 16:36:44 -0800 |
commit | 55efe20df7f2cf594786e16e890382208a114f65 (patch) | |
tree | 266f8ee2227617f7ade6a3be671bdd49782af274 /test/ipv6_enabled.rb | |
parent | 26558f816ecbe25955f549355aa57aef5959a22e (diff) | |
download | raindrops-55efe20df7f2cf594786e16e890382208a114f65.tar.gz |
Diffstat (limited to 'test/ipv6_enabled.rb')
-rw-r--r-- | test/ipv6_enabled.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/ipv6_enabled.rb b/test/ipv6_enabled.rb new file mode 100644 index 0000000..319fbef --- /dev/null +++ b/test/ipv6_enabled.rb @@ -0,0 +1,10 @@ +def ipv6_enabled? + tmp = TCPServer.new(ENV["TEST_HOST6"] || '::1', 0) + tmp.close + true + rescue => e + warn "skipping IPv6 tests, host does not seem to be IPv6 enabled:" + warn " #{e.class}: #{e}" + return false + ipv6_enabled = false +end |