summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--tests/stdlib/thttpclient.nim12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/stdlib/thttpclient.nim b/tests/stdlib/thttpclient.nim
index fff02722a..c28f09100 100644
--- a/tests/stdlib/thttpclient.nim
+++ b/tests/stdlib/thttpclient.nim
@@ -154,8 +154,20 @@ proc ipv6Test() =
   serverFd.closeSocket()
   client.close()
 
+proc longTimeoutTest() =
+# Issue #2753
+  try:
+    var client = newHttpClient(timeout = 1000)
+    var resp = client.request("https://au.yahoo.com")
+    client.close()
+  except AssertionError:
+    doAssert false, "Exceptions should not be raised"
+  except:
+    discard
+
 syncTest()
 waitFor(asyncTest())
 ipv6Test()
+longTimeoutTest()
 
 echo "OK"