home · contact · privacy
Extend ERROR regex matching tests. master
authorChristian Heller <c.heller@plomlompom.de>
Mon, 3 Nov 2025 08:51:51 +0000 (09:51 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Mon, 3 Nov 2025 08:51:51 +0000 (09:51 +0100)
src/tests/error_disconnects.test

index 290a3456f9c081e4b998742b913bba23d0c1b2fc..ac3a63ac2ca30eed98654a1f9d3cbef6aaa6d384 100644 (file)
@@ -14,6 +14,12 @@ log 1 > NICK :foo
 insert isupport-clear : +1
 log 1 $ connection_state set to: []
 log , $ DISCONNECTED
+× reconnect
+> /reconnect
+insert connecting : +1
+× disconnect-with-retry
+insert disconnecting : +1
+log 1 $ will retry connecting in 1 seconds
 ×
 
 # to prepare first test, initiate connected state
@@ -36,13 +42,21 @@ loggedservermsg 0 1 < ERROR :abc def ghi
 log 1 $ connection_state set to: [abc def ghi]
 insert disconnecting : +1
 
-# to prepare next test, get back to connected state
+# test ERROR regex (non-)matches
 > /window 1
-> /reconnect
-insert connecting : +1
-
-# test "timed out)" ERROR handling
+insert reconnect : +1
+loggedservermsg 0 1 < ERROR :Closing link: (this should not match)
+log 1 $ connection_state set to: [Closing link: (this should not match)]
+insert disconnecting : +1
+insert reconnect : +1
 loggedservermsg 0 1 < ERROR :Closing link: (Connection timed out)
 log 1 $ connection_state set to: [Closing link: (Connection timed out)]
-insert disconnecting : +1
-log 1 $ will retry connecting in 1 seconds
+insert disconnect-with-retry : +1
+insert reconnect : +1
+loggedservermsg 0 1 < ERROR :closing Link: (connection timed out)
+log 1 $ connection_state set to: [closing Link: (connection timed out)]
+insert disconnect-with-retry : +1
+insert reconnect : +1
+loggedservermsg 0 1 < ERROR :Closing link: (Ping timeout: 240 seconds)
+log 1 $ connection_state set to: [Closing link: (Ping timeout: 240 seconds)]
+insert disconnect-with-retry : +1