about summary refs log tree commit diff
path: root/src/testsuite/connect-ssl-cert1-test.e
diff options
context:
space:
mode:
authorJohann Hartwig Hauschild <git@hauschild.it>2020-04-25 00:04:38 +0200
committerJohann Hartwig Hauschild <git@hauschild.it>2020-04-25 00:04:38 +0200
commit11ea6a5070e27194a28267937067203d13e5b4a4 (patch)
treef9ffca4a89f44ccaae79a3471786862b10d44fc6 /src/testsuite/connect-ssl-cert1-test.e
parent86f3c563d6a6f86fd4f8c9fc303808bbf85d29c3 (diff)
downloadngircd-11ea6a5070e27194a28267937067203d13e5b4a4.tar.gz
ngircd-11ea6a5070e27194a28267937067203d13e5b4a4.zip
updating testsuite to support ssl-tests
Diffstat (limited to 'src/testsuite/connect-ssl-cert1-test.e')
-rw-r--r--src/testsuite/connect-ssl-cert1-test.e21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/testsuite/connect-ssl-cert1-test.e b/src/testsuite/connect-ssl-cert1-test.e
new file mode 100644
index 00000000..6a8c1b6f
--- /dev/null
+++ b/src/testsuite/connect-ssl-cert1-test.e
@@ -0,0 +1,21 @@
+# ngIRCd test suite
+# Server connect test
+
+spawn openssl s_client -quiet -connect 127.0.0.1:6697
+expect {
+        timeout { exit 1 }
+        "*CN = my.first.domain.tld"
+}
+
+sleep 2
+send "oper\r"
+expect {
+	timeout { exit 1 }
+	"451"
+}
+
+send "quit\r"
+expect {
+	timeout { exit 1 }
+	"Connection closed"
+}