git » chasquid » commit 8769e01

test: Update haproxy test config

author Alberto Bertogli
2020-11-22 09:32:26 UTC
committer Alberto Bertogli
2020-11-22 09:35:08 UTC
parent a9d7e36d29a07cb5c2703fd8def22f206f34cb27

test: Update haproxy test config

The haproxy test config includes an obsolete "debug" entry, and is
missing some timeouts which, while harmless in this context, cause a
warning that can be confusing.

This patch fixes the debug entry by running haproxy -d as recommended,
and adds the essential timeouts to avoid the warning.

test/t-18-haproxy/haproxy.cfg +3 -3
test/t-18-haproxy/run.sh +1 -1

diff --git a/test/t-18-haproxy/haproxy.cfg b/test/t-18-haproxy/haproxy.cfg
index 90dafad..96047bc 100644
--- a/test/t-18-haproxy/haproxy.cfg
+++ b/test/t-18-haproxy/haproxy.cfg
@@ -1,7 +1,7 @@
-global
-	debug
-
 listen smtp-in
 	mode tcp
 	bind *:1025
 	server srv1 localhost:2025 send-proxy
+	timeout connect 10s
+	timeout client 10s
+	timeout server 10s
diff --git a/test/t-18-haproxy/run.sh b/test/t-18-haproxy/run.sh
index 2bb7351..e2f0e9d 100755
--- a/test/t-18-haproxy/run.sh
+++ b/test/t-18-haproxy/run.sh
@@ -19,7 +19,7 @@ timeout 2m
 # Launch haproxy in the background, checking config first to fail fast in that
 # case.
 haproxy -f haproxy.cfg -c
-haproxy -f haproxy.cfg > .logs/haproxy.log 2>&1 &
+haproxy -f haproxy.cfg -d > .logs/haproxy.log 2>&1 &
 
 generate_certs_for testserver
 add_user user@testserver secretpassword