summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJeremy Harris <jgh146exb@wizmail.org>2012-07-08 22:49:18 +0100
committerJeremy Harris <jgh146exb@wizmail.org>2012-07-08 22:49:18 +0100
commit846726c5a374d833fb5211dde62ae6bceb6841c7 (patch)
tree2979952f9671639681283f694827bd3aa82d16d1 /test
parentb5b871aca49fbf0fcc2c91997e70c3c57f77faa9 (diff)
Multiple headers_add/remove options per router/transport - fixes bug 337
Diffstat (limited to 'test')
-rw-r--r--test/confs/04812
-rw-r--r--test/log/04813
-rw-r--r--test/mail/0481.userx13
-rw-r--r--test/scripts/0000-Basic/04817
4 files changed, 24 insertions, 1 deletions
diff --git a/test/confs/0481 b/test/confs/0481
index be3f923dd..212af518d 100644
--- a/test/confs/0481
+++ b/test/confs/0481
@@ -23,6 +23,7 @@ r1:
r2:
driver = redirect
+ headers_remove = Remove-Me-Also:
headers_remove = Remove-Me:
data = $local_part@domain
@@ -30,6 +31,7 @@ r3:
driver = accept
headers_remove = Remove-Me:
headers_add = X-Was-Remove-Me: >$h_remove-me:<
+ headers_add = ${if def:h_remove-me-also {X-Was-Remove-Me-Also: >$h_remove-me-also:<}}
transport = t1
diff --git a/test/log/0481 b/test/log/0481
index 3c0b2ab01..b95b0950a 100644
--- a/test/log/0481
+++ b/test/log/0481
@@ -1,3 +1,6 @@
1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@myhost.test.ex U=CALLER P=local S=sss
1999-03-02 09:44:33 10HmaX-0005vi-00 => userx <userx@myhost.test.ex> R=r3 T=t1
1999-03-02 09:44:33 10HmaX-0005vi-00 Completed
+1999-03-02 09:44:33 10HmaY-0005vi-00 <= CALLER@myhost.test.ex U=CALLER P=local S=sss
+1999-03-02 09:44:33 10HmaY-0005vi-00 => userx <userx@myhost.test.ex> R=r3 T=t1
+1999-03-02 09:44:33 10HmaY-0005vi-00 Completed
diff --git a/test/mail/0481.userx b/test/mail/0481.userx
index a9f142c35..07700dd92 100644
--- a/test/mail/0481.userx
+++ b/test/mail/0481.userx
@@ -10,3 +10,16 @@ Date: Tue, 2 Mar 1999 09:44:33 +0000
X-Was-Remove-Me: >this header is to be removed<
+From CALLER@myhost.test.ex Tue Mar 02 09:44:33 1999
+Received: from CALLER by myhost.test.ex with local (Exim x.yz)
+ (envelope-from <CALLER@myhost.test.ex>)
+ id 10HmaY-0005vi-00
+ for userx@myhost.test.ex; Tue, 2 Mar 1999 09:44:33 +0000
+Another: This is another header
+Message-Id: <E10HmaY-0005vi-00@myhost.test.ex>
+From: CALLER_NAME <CALLER@myhost.test.ex>
+Date: Tue, 2 Mar 1999 09:44:33 +0000
+X-Was-Remove-Me: >this header is to be removed<
+X-Was-Remove-Me-Also: >me too!<
+
+
diff --git a/test/scripts/0000-Basic/0481 b/test/scripts/0000-Basic/0481
index 3f308f992..d1a9a4a70 100644
--- a/test/scripts/0000-Basic/0481
+++ b/test/scripts/0000-Basic/0481
@@ -1,5 +1,10 @@
-# remove_headers and trailing colons
+# multiple remove_headers and trailing colons
exim -odi userx
Remove-Me: this header is to be removed
Another: This is another header
****
+exim -odi userx
+Remove-Me: this header is to be removed
+Another: This is another header
+Remove-Me-Also: me too!
+****