From a04185284e815e6e94613da045da770e562fce28 Mon Sep 17 00:00:00 2001 From: Jeremy Harris Date: Sat, 6 Feb 2016 19:20:06 +0000 Subject: [PATCH] Testsuite: allow for different data arrival in SMTP synch check --- test/log/0300 | 12 ++++++------ test/log/0301 | 2 +- test/rejectlog/0300 | 12 ++++++------ test/rejectlog/0301 | 2 +- test/runtest | 6 +++++- test/scripts/0000-Basic/0300 | 1 + test/scripts/0000-Basic/0301 | 1 + 7 files changed, 21 insertions(+), 15 deletions(-) diff --git a/test/log/0300 b/test/log/0300 index 1008e4be4..df59db2fe 100644 --- a/test/log/0300 +++ b/test/log/0300 @@ -1,13 +1,13 @@ 1999-03-02 09:44:33 exim x.yz daemon started: pid=pppp, no queue runs, listening for SMTP on port 1225 -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "ehlo abcd" H=[127.0.0.1] next input="mail from:\r\n" +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "ehlo abcd" H=[127.0.0.1] next input="mail fr 1999-03-02 09:44:33 10HmaX-0005vi-00 <= userx@test.ex H=(abcd) [127.0.0.1] P=esmtp S=sss 1999-03-02 09:44:33 10HmaX-0005vi-00 => :blackhole: R=r1 1999-03-02 09:44:33 10HmaX-0005vi-00 Completed -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(abcd) [127.0.0.1] next input="the message\r\nsecond line\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [127.0.0.1] next input="rcpt to:\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [ip4.ip4.ip4.ip4] next input="rcpt to:\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "junk1" H=[ip4.ip4.ip4.ip4] next input="junk2\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "rset" H=(abcd) [ip4.ip4.ip4.ip4] next input="quit\r\n" +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(abcd) [127.0.0.1] next input="the mes +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [127.0.0.1] next input="rcpt to +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [ip4.ip4.ip4.ip4] next input="rcpt to +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "junk1" H=[ip4.ip4.ip4.ip4] next input="junk2\r +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "rset" H=(abcd) [ip4.ip4.ip4.ip4] next input="quit\r\ 1999-03-02 09:44:33 10HmaY-0005vi-00 <= userx@test.ex H=(dis.able) [127.0.0.1] P=esmtp S=sss 1999-03-02 09:44:33 10HmaY-0005vi-00 => :blackhole: R=r1 1999-03-02 09:44:33 10HmaY-0005vi-00 Completed diff --git a/test/log/0301 b/test/log/0301 index fa5ac5894..2edabd78a 100644 --- a/test/log/0301 +++ b/test/log/0301 @@ -1,4 +1,4 @@ 1999-03-02 09:44:33 exim x.yz daemon started: pid=pppp, no queue runs, listening for SMTP on port 1225 1999-03-02 09:44:33 10HmaX-0005vi-00 <= userx@test.ex H=(abcd) [127.0.0.1] P=esmtp S=sss 1999-03-02 09:44:33 10HmaY-0005vi-00 <= userx@test.ex H=(abcd) [127.0.0.1] P=esmtp S=sss -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(en.force) [127.0.0.1] next input="the message\r\n" +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(en.force) [127.0.0.1] next input="the mes diff --git a/test/rejectlog/0300 b/test/rejectlog/0300 index d330f46cd..5554fb450 100644 --- a/test/rejectlog/0300 +++ b/test/rejectlog/0300 @@ -1,7 +1,7 @@ -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "ehlo abcd" H=[127.0.0.1] next input="mail from:\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(abcd) [127.0.0.1] next input="the message\r\nsecond line\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [127.0.0.1] next input="rcpt to:\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [ip4.ip4.ip4.ip4] next input="rcpt to:\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "junk1" H=[ip4.ip4.ip4.ip4] next input="junk2\r\n" -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "rset" H=(abcd) [ip4.ip4.ip4.ip4] next input="quit\r\n" +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "ehlo abcd" H=[127.0.0.1] next input="mail fr +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(abcd) [127.0.0.1] next input="the mes +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [127.0.0.1] next input="rcpt to +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "mail from:" H=(abcd) [ip4.ip4.ip4.ip4] next input="rcpt to +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "junk1" H=[ip4.ip4.ip4.ip4] next input="junk2\r +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was not advertised): rejected "rset" H=(abcd) [ip4.ip4.ip4.ip4] next input="quit\r\ 1999-03-02 09:44:33 SMTP protocol synchronization error (input sent without waiting for greeting): rejected connection from H=[127.0.0.1] input="helo abcd\r\n" diff --git a/test/rejectlog/0301 b/test/rejectlog/0301 index 24a81c867..e6346cd9f 100644 --- a/test/rejectlog/0301 +++ b/test/rejectlog/0301 @@ -1 +1 @@ -1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(en.force) [127.0.0.1] next input="the message\r\n" +1999-03-02 09:44:33 SMTP protocol synchronization error (next input sent too soon: pipelining was advertised): rejected "data" H=(en.force) [127.0.0.1] next input="the mes diff --git a/test/runtest b/test/runtest index d9aa97fa5..efcd3ed1c 100755 --- a/test/runtest +++ b/test/runtest @@ -1406,6 +1406,10 @@ $munges = 'sys_bindir' => { 'mainlog' => 's%/(usr/)?bin/%SYSBINDIR/%' }, + 'sync_check_data' => + { 'mainlog' => 's/^(.* SMTP protocol synchronization error .* next input=.{8}).*$/$1/', + 'rejectlog' => 's/^(.* SMTP protocol synchronization error .* next input=.{8}).*$/$1/'}, + }; @@ -3769,7 +3773,7 @@ $0 = "[runtest $testno]"; log_failure($log_failed_filename, $testno, "exit code unexpected") if (/^c$/i && $force_continue); if ($force_continue) { - print "stderr tail:\n"; + print "\nstderr tail:\n"; print "===================\n"; system("tail -20 test-stderr"); print "===================\n"; diff --git a/test/scripts/0000-Basic/0300 b/test/scripts/0000-Basic/0300 index 047dba410..920f12b5d 100644 --- a/test/scripts/0000-Basic/0300 +++ b/test/scripts/0000-Basic/0300 @@ -1,5 +1,6 @@ # SMTP synchronization checks, with and without PIPELINING need_ipv4 +munge sync_check_data # exim -DSERVER=server -bd -oX PORT_D **** diff --git a/test/scripts/0000-Basic/0301 b/test/scripts/0000-Basic/0301 index 08996c7ef..45a824285 100644 --- a/test/scripts/0000-Basic/0301 +++ b/test/scripts/0000-Basic/0301 @@ -1,5 +1,6 @@ # SMTP synchronization checks disabled, with and without PIPELINING need_ipv4 +munge sync_check_data # exim -DSERVER=server -bd -oX PORT_D **** -- 2.30.2