diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-05-31 15:19:43 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-05-31 15:19:43 +0100 |
commit | cc7f49b369afad5a061603f73ce1445cafec07fa (patch) | |
tree | 62ac60fb4bb2d6aaf6ecb96fe789c86a1a36a1ec /test/functional/cases | |
parent | 1e3d20ef442cfc7260aa4b2e26f0f827ba615036 (diff) | |
download | rspamd-cc7f49b369afad5a061603f73ce1445cafec07fa.tar.gz rspamd-cc7f49b369afad5a061603f73ce1445cafec07fa.zip |
[Test] Add functional tests for ssl in lua_tcp
Diffstat (limited to 'test/functional/cases')
-rw-r--r-- | test/functional/cases/230_tcp.robot | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/test/functional/cases/230_tcp.robot b/test/functional/cases/230_tcp.robot index 4d8b2fbd6..cbdbc6640 100644 --- a/test/functional/cases/230_tcp.robot +++ b/test/functional/cases/230_tcp.robot @@ -1,6 +1,6 @@ *** Settings *** -Test Setup Http Setup -Test Teardown Http Teardown +Test Setup Servers Setup +Test Teardown Servers Teardown Library Process Library ${TESTDIR}/lib/rspamd.py Resource ${TESTDIR}/lib/rspamd.robot @@ -19,6 +19,10 @@ Simple TCP request Check Rspamc ${result} HTTP_ASYNC_RESPONSE Check Rspamc ${result} HTTP_ASYNC_RESPONSE_2 +SSL TCP request + ${result} = Scan Message With Rspamc ${MESSAGE} + Check Rspamc ${result} TCP_SSL_RESPONSE (0.00)[test] + Check Rspamc ${result} TCP_SSL_RESPONSE_2 (0.00)[test2] Sync API TCP request ${result} = Scan Message With Rspamc ${MESSAGE} @@ -41,20 +45,27 @@ Lua Setup Set Global Variable ${LUA_SCRIPT} Generic Setup -Http Setup +Servers Setup Run Dummy Http + Run Dummy Ssl Lua Setup ${TESTDIR}/lua/tcp.lua -Http Teardown +Servers Teardown ${http_pid} = Get File /tmp/dummy_http.pid Shutdown Process With Children ${http_pid} + ${ssl_pid} = Get File /tmp/dummy_ssl.pid + Shutdown Process With Children ${ssl_pid} Normal Teardown Run Dummy Http [Arguments] ${result} = Start Process ${TESTDIR}/util/dummy_http.py - Wait Until Created /tmp/dummy_http.pid + Wait Until Created /tmp/dummy_http.pid timeout=2 second +Run Dummy Ssl + [Arguments] + ${result} = Start Process ${TESTDIR}/util/dummy_ssl.py ${TESTDIR}/util/server.pem + Wait Until Created /tmp/dummy_ssl.pid timeout=2 second Check url [Arguments] ${url} ${method} @{expect_results} |