diff options
author | Eric Wong <normalperson@yhbt.net> | 2011-03-01 14:47:42 -0800 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2011-03-01 14:50:16 -0800 |
commit | 16201f3c16b66beb9694eff2bed2f4b8ccd1f010 (patch) | |
tree | 8a02cf434064e67e14c9769018185766ce779271 | |
parent | 943fbb44f7b2194311ac614c3a6c54420c8dda94 (diff) | |
download | raindrops-16201f3c16b66beb9694eff2bed2f4b8ccd1f010.tar.gz |
UGH...
-rw-r--r-- | test/test_linux_tcp_info.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/test/test_linux_tcp_info.rb b/test/test_linux_tcp_info.rb index bfa7eb3..e008a92 100644 --- a/test/test_linux_tcp_info.rb +++ b/test/test_linux_tcp_info.rb @@ -9,12 +9,16 @@ class TestLinuxTCP_Info < Test::Unit::TestCase TEST_ADDR = ENV['UNICORN_TEST_ADDR'] || '127.0.0.1' + # Linux kernel commit 5ee3afba88f5a79d0bff07ddd87af45919259f91 + TCP_INFO_useful_listenq = `uname -r`.strip >= '2.6.24' + def test_tcp_server s = TCPServer.new(TEST_ADDR, 0) rv = Raindrops::TCP_Info.new s c = TCPSocket.new TEST_ADDR, s.addr[1] tmp = Raindrops::TCP_Info.new s - assert_equal 1, tmp.unacked + TCP_INFO_useful_listenq and assert_equal 1, tmp.unacked + assert_equal 0, rv.unacked a = s.accept tmp = Raindrops::TCP_Info.new s |