[exim-cvs] Testsuite: expand testcase. Bug 2693

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Exim Git Commits Mailing List
Date:  
À: exim-cvs
Sujet: [exim-cvs] Testsuite: expand testcase. Bug 2693
Gitweb: https://git.exim.org/exim.git/commitdiff/5ce86c4f552071ad7408c40324d5211ab2a2da82
Commit:     5ce86c4f552071ad7408c40324d5211ab2a2da82
Parent:     b664a2512489bbeab422ff4bb8329591903d9341
Author:     Simon Arlott <bugzilla.exim.simon@???>
AuthorDate: Mon Feb 8 19:04:30 2021 +0000
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Mon Feb 8 19:06:22 2021 +0000


    Testsuite: expand testcase.  Bug 2693
---
 test/confs/0622              |  9 +++------
 test/log/0622                | 43 ++++++++++++++++++++++++++++++++++++++++++-
 test/rejectlog/0622          |  7 +++++++
 test/scripts/0000-Basic/0622 | 25 +++++++++++++++++++++++++
 4 files changed, 77 insertions(+), 7 deletions(-)


diff --git a/test/confs/0622 b/test/confs/0622
index 5dc3e0f..8f9d719 100644
--- a/test/confs/0622
+++ b/test/confs/0622
@@ -1,24 +1,20 @@
# Exim test configuration 0622

SERVER=
+HAP=

.include DIR/aux-var/std_conf_prefix

primary_hostname = myhost.test.ex
-log_selector = +pipelining +received_recipients
+log_selector = +pipelining +received_recipients +smtp_connection


# ----- Main settings -----

-acl_smtp_connect = check_connect
acl_smtp_rcpt = check_rcpt

begin acl

-check_connect:
-    accept
-        logwrite = :main:New connection
-
 check_rcpt:
     defer
         condition = ${if eq {$acl_m0}{1}}
@@ -67,6 +63,7 @@ send_to_server:
   hosts = 127.0.0.1
   port = PORT_D
   max_rcpt = 0
+  HAP


# ----- Retry -----

diff --git a/test/log/0622 b/test/log/0622
index 7f8edd2..3d6843d 100644
--- a/test/log/0622
+++ b/test/log/0622
@@ -6,10 +6,25 @@
1999-03-02 09:44:33 10HmaX-0005vi-00 -> e@??? <E@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] L C="250 OK id=10HmaZ-0005vi-00"
1999-03-02 09:44:33 10HmaX-0005vi-00 -> f@??? <F@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] L C="250 OK id=10HmaZ-0005vi-00"
1999-03-02 09:44:33 10HmaX-0005vi-00 Completed
+1999-03-02 09:44:33 10HmbB-0005vi-00 <= CALLER@??? U=CALLER P=local S=sss for A@??? B@??? C@??? D@??? E@??? F@???
+1999-03-02 09:44:33 10HmbB-0005vi-00 => a@??? <A@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK id=10HmbC-0005vi-00"
+1999-03-02 09:44:33 10HmbB-0005vi-00 == b@??? <B@???> R=client T=send_to_server defer (-44) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<B@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbB-0005vi-00 == c@??? <C@???> R=client T=send_to_server defer (-44) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<C@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbB-0005vi-00 == d@??? <D@???> R=client T=send_to_server defer (-44) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<D@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbB-0005vi-00 == e@??? <E@???> R=client T=send_to_server defer (-44) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<E@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbB-0005vi-00 == f@??? <F@???> R=client T=send_to_server defer (-44) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<F@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbB-0005vi-00 => b@??? <B@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK id=10HmbD-0005vi-00"
+1999-03-02 09:44:33 10HmbB-0005vi-00 == c@??? <C@???> R=client T=send_to_server defer (-44) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<C@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbB-0005vi-00 == d@??? <D@???> R=client T=send_to_server defer (-44) H=127.0.0.1 [127.0.0.1]: SMTP error from remote mail server after RCPT TO:<D@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbB-0005vi-00 -> e@??? <E@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK id=10HmbD-0005vi-00"
+1999-03-02 09:44:33 10HmbB-0005vi-00 -> f@??? <F@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK id=10HmbD-0005vi-00"
+1999-03-02 09:44:33 10HmbB-0005vi-00 => c@??? <C@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK id=10HmbE-0005vi-00"
+1999-03-02 09:44:33 10HmbB-0005vi-00 -> d@??? <D@???> R=client T=send_to_server H=127.0.0.1 [127.0.0.1] C="250 OK id=10HmbE-0005vi-00"
+1999-03-02 09:44:33 10HmbB-0005vi-00 Completed

******** SERVER ********
1999-03-02 09:44:33 exim x.yz daemon started: pid=pppp, no queue runs, listening for SMTP on port PORT_D
-1999-03-02 09:44:33 New connection
+1999-03-02 09:44:33 SMTP connection from [127.0.0.1] (TCP/IP connection count = 1)
1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <B@???>: 452 4.5.3 Try again
1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <C@???>: 452 4.5.3 Try again
1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <D@???>: 452 4.5.3 Try again
@@ -29,3 +44,29 @@
1999-03-02 09:44:33 10HmbA-0005vi-00 => :blackhole: <D@???> R=server
1999-03-02 09:44:33 10HmbA-0005vi-00 => :blackhole: <C@???> R=server
1999-03-02 09:44:33 10HmbA-0005vi-00 Completed
+1999-03-02 09:44:33 SMTP connection from localhost (myhost.test.ex) [127.0.0.1] closed by QUIT
+1999-03-02 09:44:33 SMTP connection from [127.0.0.1] (TCP/IP connection count = 1)
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <B@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <C@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <D@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <E@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <F@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbC-0005vi-00 <= CALLER@??? H=localhost (myhost.test.ex) [127.0.0.1] P=esmtp L- S=sss id=E10HmbB-0005vi-00@??? for A@???
+1999-03-02 09:44:33 10HmbC-0005vi-00 => :blackhole: <A@???> R=server
+1999-03-02 09:44:33 10HmbC-0005vi-00 Completed
+1999-03-02 09:44:33 SMTP connection from localhost (myhost.test.ex) [127.0.0.1] closed by QUIT
+1999-03-02 09:44:33 SMTP connection from [127.0.0.1] (TCP/IP connection count = 1)
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <C@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <D@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 10HmbD-0005vi-00 <= CALLER@??? H=localhost (myhost.test.ex) [127.0.0.1] P=esmtp L- S=sss id=E10HmbB-0005vi-00@??? for B@??? E@??? F@???
+1999-03-02 09:44:33 10HmbD-0005vi-00 => :blackhole: <F@???> R=server
+1999-03-02 09:44:33 10HmbD-0005vi-00 => :blackhole: <E@???> R=server
+1999-03-02 09:44:33 10HmbD-0005vi-00 => :blackhole: <B@???> R=server
+1999-03-02 09:44:33 10HmbD-0005vi-00 Completed
+1999-03-02 09:44:33 SMTP connection from localhost (myhost.test.ex) [127.0.0.1] closed by QUIT
+1999-03-02 09:44:33 SMTP connection from [127.0.0.1] (TCP/IP connection count = 1)
+1999-03-02 09:44:33 10HmbE-0005vi-00 <= CALLER@??? H=localhost (myhost.test.ex) [127.0.0.1] P=esmtp L- S=sss id=E10HmbB-0005vi-00@??? for C@??? D@???
+1999-03-02 09:44:33 10HmbE-0005vi-00 => :blackhole: <D@???> R=server
+1999-03-02 09:44:33 10HmbE-0005vi-00 => :blackhole: <C@???> R=server
+1999-03-02 09:44:33 10HmbE-0005vi-00 Completed
+1999-03-02 09:44:33 SMTP connection from localhost (myhost.test.ex) [127.0.0.1] closed by QUIT
diff --git a/test/rejectlog/0622 b/test/rejectlog/0622
index 701e354..f92d046 100644
--- a/test/rejectlog/0622
+++ b/test/rejectlog/0622
@@ -7,3 +7,10 @@
1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <F@???>: 452 4.5.3 Try again
1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <C@???>: 452 4.5.3 Try again
1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <D@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <B@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <C@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <D@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <E@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <F@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <C@???>: 452 4.5.3 Try again
+1999-03-02 09:44:33 H=localhost (myhost.test.ex) [127.0.0.1] F=<CALLER@???> temporarily rejected RCPT <D@???>: 452 4.5.3 Try again
diff --git a/test/scripts/0000-Basic/0622 b/test/scripts/0000-Basic/0622
index 096980b..e98a53a 100644
--- a/test/scripts/0000-Basic/0622
+++ b/test/scripts/0000-Basic/0622
@@ -8,10 +8,35 @@ To: A@???,B@???,C@???,D@???,E@???,F@???

 Testing
 ****
+# "A" should go throuugh as one MAIL FROM message, B,E,F as a second, C,D
+# as a third - due to the server responses.  Note that the client logging
+# gets overlapped; look at the server's id= logged with the 250 by the client.
 exim -M $msg1
 ****
 #
 #
+#
+#
+# Repeat without pipelining, just as a baseline check.
+# The optimisation, that does another message attempt immediately on the open
+# connection, is only there for the pipelined case at present.  So we must
+# kick the message three times for three separate connections.
+# (A possible enhancement, if anyone cares.  "first_addr" in
+# smtp_deliver/sync_responses is the key).
+#
+exim -odq -t
+To: A@???,B@???,C@???,D@???,E@???,F@???
+     
+Testing
+****
+exim -DHAP=hosts_avoid_pipelining=127.0.0.1 -M $msg1
+****
+exim -DHAP=hosts_avoid_pipelining=127.0.0.1 -M $msg1
+****
+exim -DHAP=hosts_avoid_pipelining=127.0.0.1 -M $msg1
+****
+#
+#
 killdaemon
 no_msglog_check
 sleep 1