summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorPhilip Hazel <ph10@hermes.cam.ac.uk>2006-11-14 16:40:36 +0000
committerPhilip Hazel <ph10@hermes.cam.ac.uk>2006-11-14 16:40:36 +0000
commit4e88a19f714c90a9381432c7562bd35446fd1f98 (patch)
tree9f62c6dd32227f77e21987ec39b55dd000731764 /test
parent734e149965a807226eb5b87e9e13fda85a48b027 (diff)
Applied a modified version of Brad Jorsch's patch for "message" with
"accept".
Diffstat (limited to 'test')
-rw-r--r--test/confs/00232
-rw-r--r--test/confs/054646
-rw-r--r--test/log/05463
-rw-r--r--test/paniclog/05462
-rwxr-xr-xtest/runtest4
-rw-r--r--test/scripts/0000-Basic/054619
-rw-r--r--test/stderr/05462
-rw-r--r--test/stdout/00232
-rw-r--r--test/stdout/054620
9 files changed, 96 insertions, 4 deletions
diff --git a/test/confs/0023 b/test/confs/0023
index be99eb00f..ac6d8f7e2 100644
--- a/test/confs/0023
+++ b/test/confs/0023
@@ -203,7 +203,7 @@ acl_56_56_56:
accept
acl_56_56_57:
- accept message = denied by condition
+ accept message = accepted by condition
condition = ${substr_5:$local_part}
acl_56_56_58:
diff --git a/test/confs/0546 b/test/confs/0546
new file mode 100644
index 000000000..736c126a8
--- /dev/null
+++ b/test/confs/0546
@@ -0,0 +1,46 @@
+# Exim test configuration 0546
+
+HELO_MSG=One line
+RCPT_MSG=RCPT is OK
+
+exim_path = EXIM_PATH
+host_lookup_order = bydns
+rfc1413_query_timeout = 0s
+spool_directory = DIR/spool
+log_file_path = DIR/spool/log/%slog
+gecos_pattern = ""
+gecos_name = CALLER_NAME
+
+# ----- Main settings -----
+
+acl_smtp_helo = check_helo
+acl_smtp_mail = check_mail
+acl_smtp_rcpt = check_rcpt
+acl_smtp_data = check_data
+acl_smtp_predata = check_predata
+
+qualify_domain = test.ex
+queue_only
+
+
+# ----- ACLs -----
+
+begin acl
+
+check_helo:
+ accept message = HELO_MSG
+
+check_mail:
+ accept message = 299 MAIL is\nOK
+
+check_rcpt:
+ accept message = RCPT_MSG
+
+check_data:
+ accept message = 288 I like the data
+
+check_predata:
+ accept message = 300 Funny, but OK code
+
+
+# End
diff --git a/test/log/0546 b/test/log/0546
new file mode 100644
index 000000000..f1b6d35cb
--- /dev/null
+++ b/test/log/0546
@@ -0,0 +1,3 @@
+1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@test.ex U=CALLER P=local-esmtp S=sss
+1999-03-02 09:44:33 EHLO/HELO response must not contain newlines: message truncated: 250 Two\nlines
+1999-03-02 09:44:33 configured error code starts with incorrect digit (expected 2) in "450 Bad number"
diff --git a/test/paniclog/0546 b/test/paniclog/0546
new file mode 100644
index 000000000..e21dfb1f3
--- /dev/null
+++ b/test/paniclog/0546
@@ -0,0 +1,2 @@
+1999-03-02 09:44:33 EHLO/HELO response must not contain newlines: message truncated: 250 Two\nlines
+1999-03-02 09:44:33 configured error code starts with incorrect digit (expected 2) in "450 Bad number"
diff --git a/test/runtest b/test/runtest
index a169d1550..aee2697ad 100755
--- a/test/runtest
+++ b/test/runtest
@@ -1,6 +1,6 @@
#! /usr/bin/perl -w
-# $Cambridge: exim/test/runtest,v 1.18 2006/11/07 15:11:34 ph10 Exp $
+# $Cambridge: exim/test/runtest,v 1.19 2006/11/14 16:40:36 ph10 Exp $
###############################################################################
# This is the controlling script for the "new" test suite for Exim. It should #
@@ -1514,7 +1514,7 @@ if (/^server\s+(.*)$/)
# This gives the server time to get started; otherwise the next
# process may not find it there when it expects it.
- select(undef, undef, undef, 0.05);
+ select(undef, undef, undef, 0.5);
return 3;
}
diff --git a/test/scripts/0000-Basic/0546 b/test/scripts/0000-Basic/0546
new file mode 100644
index 000000000..1486d3538
--- /dev/null
+++ b/test/scripts/0000-Basic/0546
@@ -0,0 +1,19 @@
+# User messages for "accept" verbs
+need_ipv4
+#
+exim -bs
+ehlo a.b.c
+mail from:<>
+rcpt to:<userx@test.ex>
+data
+This is a test
+.
+quit
+****
+exim -bs -DHELO_MSG='Two\nlines' -DRCPT_MSG='450 Bad number'
+ehlo a.b.c
+mail from:<>
+rcpt to:<userx@test.ex>
+quit
+****
+no_msglog_check
diff --git a/test/stderr/0546 b/test/stderr/0546
new file mode 100644
index 000000000..e21dfb1f3
--- /dev/null
+++ b/test/stderr/0546
@@ -0,0 +1,2 @@
+1999-03-02 09:44:33 EHLO/HELO response must not contain newlines: message truncated: 250 Two\nlines
+1999-03-02 09:44:33 configured error code starts with incorrect digit (expected 2) in "450 Bad number"
diff --git a/test/stdout/0023 b/test/stdout/0023
index e7eb769ee..266184af0 100644
--- a/test/stdout/0023
+++ b/test/stdout/0023
@@ -422,7 +422,7 @@
221 myhost.test.ex closing connection
220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
250 OK
-250 Accepted
+250 accepted by condition
354 Enter message, ending with "." on a line by itself
250 OK id=10HmbK-0005vi-00
250 OK
diff --git a/test/stdout/0546 b/test/stdout/0546
new file mode 100644
index 000000000..0865c5f17
--- /dev/null
+++ b/test/stdout/0546
@@ -0,0 +1,20 @@
+220 the.local.host.name ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
+250-One line
+250-SIZE 52428800
+250-PIPELINING
+250 HELP
+299-MAIL is
+299 OK
+250 RCPT is OK
+300 Funny, but OK code
+288 I like the data
+221 the.local.host.name closing connection
+220 the.local.host.name ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
+250-Two
+250-SIZE 52428800
+250-PIPELINING
+250 HELP
+299-MAIL is
+299 OK
+250 Bad number
+221 the.local.host.name closing connection