summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMatthias Kurz <m.kurz@irregular.at>2018-09-28 23:05:02 +0100
committerJeremy Harris <jgh146exb@wizmail.org>2018-09-28 23:18:42 +0100
commit4e9287801772d5aae181a9db0ef1dd1b514b2129 (patch)
tree976a3b004a49751745f202a99a60b9f1747bb049 /test
parentffbc20ed9c9ed09a68ff0a608f623c3c83d521a8 (diff)
Events: Fire msg:fail:internal for a non-system filter "fail" command. Bug 2322
Diffstat (limited to 'test')
-rw-r--r--test/aux-fixed/5704.filter4
-rw-r--r--test/aux-fixed/5706.filter3
-rw-r--r--test/confs/570428
-rw-r--r--test/log/570412
-rw-r--r--test/scripts/5700-events/57045
5 files changed, 52 insertions, 0 deletions
diff --git a/test/aux-fixed/5704.filter b/test/aux-fixed/5704.filter
new file mode 100644
index 000000000..7d01325a3
--- /dev/null
+++ b/test/aux-fixed/5704.filter
@@ -0,0 +1,4 @@
+# Exim filter
+
+if not error_message
+then fail text "failed in system filter file" endif
diff --git a/test/aux-fixed/5706.filter b/test/aux-fixed/5706.filter
new file mode 100644
index 000000000..b434b77c2
--- /dev/null
+++ b/test/aux-fixed/5706.filter
@@ -0,0 +1,3 @@
+# Exim filter
+
+fail "failed in filter file"
diff --git a/test/confs/5704 b/test/confs/5704
new file mode 100644
index 000000000..a1749442b
--- /dev/null
+++ b/test/confs/5704
@@ -0,0 +1,28 @@
+# Exim test configuration 5704
+
+.include DIR/aux-var/std_conf_prefix
+
+# ----- Main settings -----
+
+system_filter = DIR/aux-fixed/TESTNUM.filter
+
+event_action = ${acl {logger}}
+
+# ----- ACL -----
+
+begin acl
+
+.include DIR/aux-fixed/event-logger-acl
+
+# ----- Routers -----
+
+begin routers
+
+dump_bounces:
+ driver = redirect
+ senders = :
+ data = :blackhole:
+
+# ----- Transports -----
+
+# End
diff --git a/test/log/5704 b/test/log/5704
new file mode 100644
index 000000000..ac2d365e0
--- /dev/null
+++ b/test/log/5704
@@ -0,0 +1,12 @@
+1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@the.local.host.name U=CALLER P=local S=sss
+1999-03-02 09:44:33 10HmaX-0005vi-00 cancelled by system filter: failed in system filter file
+1999-03-02 09:44:33 10HmaX-0005vi-00 event msg:fail:internal
+1999-03-02 09:44:33 10HmaX-0005vi-00 . local_part <userx> domain <domain1> reason <failed in system filter file>
+1999-03-02 09:44:33 10HmaY-0005vi-00 <= <> R=10HmaX-0005vi-00 U=EXIMUSER P=local S=sss
+1999-03-02 09:44:33 10HmaY-0005vi-00 => :blackhole: <CALLER@the.local.host.name> R=dump_bounces
+1999-03-02 09:44:33 10HmaY-0005vi-00 Completed
+1999-03-02 09:44:33 10HmaY-0005vi-00 event msg:complete
+1999-03-02 09:44:33 10HmaY-0005vi-00 . finished: 10HmaY-0005vi-00
+1999-03-02 09:44:33 10HmaX-0005vi-00 Completed
+1999-03-02 09:44:33 10HmaX-0005vi-00 event msg:complete
+1999-03-02 09:44:33 10HmaX-0005vi-00 . finished: 10HmaX-0005vi-00
diff --git a/test/scripts/5700-events/5704 b/test/scripts/5700-events/5704
new file mode 100644
index 000000000..3ed25aa74
--- /dev/null
+++ b/test/scripts/5700-events/5704
@@ -0,0 +1,5 @@
+# System filter which triggers fail command results in event.
+#
+exim -odi userx@domain1
+Processed by a system filter which triggers fail command.
+****