summaryrefslogtreecommitdiffstats
path: root/test/functional/cases
diff options
context:
space:
mode:
authorMikhail Galanin <mgalanin@mimecast.com>2018-09-10 11:02:47 +0100
committerMikhail Galanin <mgalanin@mimecast.com>2018-09-10 11:02:47 +0100
commit6990ef3daa64ad7ab9724dbb20cea92e243fb46a (patch)
tree6c08f3fa5f885c03ff719fb5fb9d9d41f48587d3 /test/functional/cases
parented1c0fe1f58697d45d35d09f3635218e346c2f9c (diff)
parent8128b539535d3c8df974ac2fee7d673f5d3c5502 (diff)
downloadrspamd-6990ef3daa64ad7ab9724dbb20cea92e243fb46a.tar.gz
rspamd-6990ef3daa64ad7ab9724dbb20cea92e243fb46a.zip
Merge branch 'master' into rspamadm-coroutines
Diffstat (limited to 'test/functional/cases')
-rw-r--r--test/functional/cases/160_antivirus.robot22
1 files changed, 21 insertions, 1 deletions
diff --git a/test/functional/cases/160_antivirus.robot b/test/functional/cases/160_antivirus.robot
index 1516ae1b5..86c2e51b0 100644
--- a/test/functional/cases/160_antivirus.robot
+++ b/test/functional/cases/160_antivirus.robot
@@ -19,12 +19,14 @@ CLAMAV MISS
Run Dummy Clam ${PORT_CLAM}
${result} = Scan Message With Rspamc ${MESSAGE}
Check Rspamc ${result} CLAM_VIRUS inverse=1
+ Shutdown clamav
CLAMAV HIT
Run Dummy Clam ${PORT_CLAM} 1
${result} = Scan Message With Rspamc ${MESSAGE2}
Check Rspamc ${result} CLAM_VIRUS (1.00)[Eicar-Test-Signature]
Should Not Contain ${result.stdout} CLAMAV_FAIL
+ Shutdown clamav
CLAMAV CACHE HIT
${result} = Scan Message With Rspamc ${MESSAGE2}
@@ -41,6 +43,7 @@ FPROT MISS
${result} = Scan Message With Rspamc ${MESSAGE2}
Check Rspamc ${result} FPROT_VIRUS inverse=1
Should Not Contain ${result.stdout} FPROT_EICAR
+ Shutdown fport
FPROT HIT - PATTERN
Run Dummy Fprot ${PORT_FPROT} 1
@@ -52,6 +55,8 @@ FPROT HIT - PATTERN
Should Contain ${result.stdout} FPROT_VIRUS_DUPLICATE_PATTERN
Should Not Contain ${result.stdout} FPROT_VIRUS_DUPLICATE_DEFAULT
Should Not Contain ${result.stdout} FPROT_VIRUS_DUPLICATE_NOPE
+ Shutdown fport
+ Shutdown fport duplicate
FPROT CACHE HIT
${result} = Scan Message With Rspamc ${MESSAGE}
@@ -75,6 +80,21 @@ Antivirus Setup
Antivirus Teardown
Normal Teardown
Shutdown Process With Children ${REDIS_PID}
+ Shutdown clamav
+ Shutdown fport
+ Terminate All Processes kill=True
+
+Shutdown clamav
+ ${clamav_pid} = Get File if exists /tmp/dummy_clamav.pid
+ Run Keyword if ${clamav_pid} Shutdown Process With Children ${clamav_pid}
+
+Shutdown fport
+ ${fport_pid} = Get File if exists /tmp/dummy_fprot.pid
+ Run Keyword if ${fport_pid} Shutdown Process With Children ${fport_pid}
+
+Shutdown fport duplicate
+ ${fport_pid} = Get File if exists /tmp/dummy_fprot_dupe.pid
+ Run Keyword if ${fport_pid} Shutdown Process With Children ${fport_pid}
Run Dummy Clam
[Arguments] ${port} ${found}=
@@ -83,5 +103,5 @@ Run Dummy Clam
Run Dummy Fprot
[Arguments] ${port} ${found}= ${pid}=/tmp/dummy_fprot.pid
- ${result} = Start Process ${TESTDIR}/util/dummy_fprot.py ${port} ${found} ${pid}
+ Start Process ${TESTDIR}/util/dummy_fprot.py ${port} ${found} ${pid}
Wait Until Created ${pid}