diff options
author | Dale Hamel <dale.hamel@shopify.com> | 2023-02-24 13:47:40 -0500 |
---|---|---|
committer | Eric Wong <bofh@yhbt.net> | 2023-02-24 19:02:18 +0000 |
commit | 10d5fb25b6319532313a3bda144c6e1a3a8c0bf4 (patch) | |
tree | 93da035fafdcddea79b53a00fc60adaa79559bd8 | |
parent | a5902f243cd245d615fc0a443c370559db9117f9 (diff) | |
download | raindrops-10d5fb25b6319532313a3bda144c6e1a3a8c0bf4.tar.gz |
It doesn't affect the test outcome, but it is not the intended behaviour of the test. We listen once to find out what port to use, then should bind with SO_REUSEPORT N-1 times, but we are doing it N times, so we have one extra listener.
-rw-r--r-- | test/test_linux_reuseport_tcp_listen_stats.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/test_linux_reuseport_tcp_listen_stats.rb b/test/test_linux_reuseport_tcp_listen_stats.rb index c977c43..73995ea 100644 --- a/test/test_linux_reuseport_tcp_listen_stats.rb +++ b/test/test_linux_reuseport_tcp_listen_stats.rb @@ -36,7 +36,7 @@ class TestLinuxReuseportTcpListenStats < Test::Unit::TestCase listeners = 10 _, port = new_socket_server(reuseport: true) addr = "#{TEST_ADDR}:#{port}" - listeners.times do + (listeners - 1).times do new_socket_server(reuseport: true, port: port) end |