rubygem-thin/0001-Fix-maximum_connections-limiting-test.patch
2021-03-19 15:14:25 +08:00

38 lines
1.2 KiB
Diff

From b7876b29c46fccd711638073a66d9c2ea76af4fe Mon Sep 17 00:00:00 2001
From: maminjie <maminjie1@huawei.com>
Date: Fri, 19 Mar 2021 14:15:32 +0800
Subject: [PATCH] Fix maximum_connections limiting test
reference to: https://github.com/macournoyer/thin/pull/360
---
spec/server_spec.rb | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/spec/server_spec.rb b/spec/server_spec.rb
index 40747cc..25fb48a 100644
--- a/spec/server_spec.rb
+++ b/spec/server_spec.rb
@@ -16,9 +16,10 @@ describe Server do
# connections, so we cannot really run this test under that
# condition.
pending("only for non-root users") if Process.euid == 0
- @server.maximum_connections = 100_000
+ maximum_connnections = 1_000_000
+ @server.maximum_connections = maximum_connnections
@server.config
- @server.maximum_connections.should < 100_000
+ @server.maximum_connections.should <= maximum_connnections
end
it "should default to non-threaded" do
@@ -102,4 +103,4 @@ describe Server, "initialization" do
Server.should_not_receive(:setup_signals)
Server.new(:signals => false)
end
-end
\ No newline at end of file
+end
--
2.23.0