You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by rd...@apache.org on 2008/12/13 16:39:31 UTC
svn commit: r726223 - in /james/server/trunk/build-tools: delivery-smtp.mpt
pop3-after-smtp.mpt smoke.xml
Author: rdonkin
Date: Sat Dec 13 07:39:30 2008
New Revision: 726223
URL: http://svn.apache.org/viewvc?rev=726223&view=rev
Log:
Added more complex SMTP->POP3 tests to check that basic delivery works ok.
Added:
james/server/trunk/build-tools/delivery-smtp.mpt (contents, props changed)
- copied, changed from r725987, james/server/trunk/build-tools/smtp.mpt
james/server/trunk/build-tools/pop3-after-smtp.mpt (contents, props changed)
- copied, changed from r726194, james/server/trunk/build-tools/pop3.mpt
Modified:
james/server/trunk/build-tools/smoke.xml
Copied: james/server/trunk/build-tools/delivery-smtp.mpt (from r725987, james/server/trunk/build-tools/smtp.mpt)
URL: http://svn.apache.org/viewvc/james/server/trunk/build-tools/delivery-smtp.mpt?p2=james/server/trunk/build-tools/delivery-smtp.mpt&p1=james/server/trunk/build-tools/smtp.mpt&r1=725987&r2=726223&rev=726223&view=diff
==============================================================================
--- james/server/trunk/build-tools/smtp.mpt (original)
+++ james/server/trunk/build-tools/delivery-smtp.mpt Sat Dec 13 07:39:30 2008
@@ -21,13 +21,13 @@
S: 250 .* Hello example.org .*
C: MAIL FROM:<jo...@example.org>
S: 250 2.1.0 Sender <jo...@example.org> OK
-C: RCPT TO:<us...@localhost>
-S: 250 2.1.5 Recipient <us...@localhost> OK
+C: RCPT TO:<jo...@localhost>
+S: 250 2.1.5 Recipient <jo...@localhost> OK
C: DATA
S: 354 Ok Send data ending with <CRLF>.<CRLF>
C: Date: 12 Dec 2008 GMT
C: From: <jo...@example.org>
-C: To: <us...@localhost>
+C: To: <jo...@localhost>
C: Subject: A Test Message
C:
C: Simple plain mail content
Propchange: james/server/trunk/build-tools/delivery-smtp.mpt
------------------------------------------------------------------------------
svn:mergeinfo =
Copied: james/server/trunk/build-tools/pop3-after-smtp.mpt (from r726194, james/server/trunk/build-tools/pop3.mpt)
URL: http://svn.apache.org/viewvc/james/server/trunk/build-tools/pop3-after-smtp.mpt?p2=james/server/trunk/build-tools/pop3-after-smtp.mpt&p1=james/server/trunk/build-tools/pop3.mpt&r1=726194&r2=726223&rev=726223&view=diff
==============================================================================
--- james/server/trunk/build-tools/pop3.mpt (original)
+++ james/server/trunk/build-tools/pop3-after-smtp.mpt Sat Dec 13 07:39:30 2008
@@ -17,10 +17,34 @@
# under the License. #
################################################################
S: \+OK .* POP3 server \(JAMES POP3 Server .*
-C: USER user
+C: USER john.smith
S: \+OK
C: PASS passwd
-S: \+OK Welcome user
+S: \+OK Welcome john.smith
+C: STAT
+S: \+OK 1 .*
+C: RETR 1
+S: \+OK Message follows
+S: Message-ID: .*
+S: MIME-Version: 1.0
+S: Return-Path: <jo...@example.org>
+S: Content-Type: text/plain; charset=us-ascii
+S: Content-Transfer-Encoding: 7bit
+S: Delivered-To: john.smith@localhost
+S: Received: from localhost.*
+S: .*by localhost.*
+S: .*for <jo...@localhost>;
+S: .*
+S: Date: .*
+S: From: <jo...@example.org>
+S: To: <jo...@localhost>
+S: Subject: A Test Message
+S:
+S: Simple plain mail content
+S:
+S: .
+C: DELE 1
+S: \+OK Message deleted
C: STAT
S: \+OK 0 0
C: QUIT
Propchange: james/server/trunk/build-tools/pop3-after-smtp.mpt
------------------------------------------------------------------------------
svn:mergeinfo =
Modified: james/server/trunk/build-tools/smoke.xml
URL: http://svn.apache.org/viewvc/james/server/trunk/build-tools/smoke.xml?rev=726223&r1=726222&r2=726223&view=diff
==============================================================================
--- james/server/trunk/build-tools/smoke.xml (original)
+++ james/server/trunk/build-tools/smoke.xml Sat Dec 13 07:39:30 2008
@@ -29,6 +29,17 @@
<echo>This is a library containing macros required for smoke tests.</echo>
</target>
+ <macrodef name='TestDelivery'>
+ <attribute name='smtp' default='delivery-smtp'/>
+ <attribute name='pop3' default='pop3-after-smtp'/>
+ <sequential>
+ <TestProtocol port='${org.apache.james.smoke.port.SMTP}' name='@{smtp}'/>
+ <echo>Allow spool to delivery message...</echo>
+ <sleep seconds="10"/>
+ <mpt:mpt port='${org.apache.james.smoke.port.POP3}' script='../build-tools/@{pop3}.mpt'/>
+ </sequential>
+ </macrodef>
+
<macrodef name='TestProtocol'>
<attribute name='port'/>
<!-- Use simple convention that script is named from protocol -->
@@ -66,10 +77,12 @@
</classpath>
</taskdef>
+ <TestProtocol port='${org.apache.james.smoke.port.POP3}' name='pop3'/>
<TestProtocol port='${org.apache.james.smoke.port.IMAP}' name='imap'/>
<TestProtocol port='${org.apache.james.smoke.port.SMTP}' name='smtp'/>
- <TestProtocol port='${org.apache.james.smoke.port.POP3}' name='pop3'/>
- <TestProtocol port='${org.apache.james.smoke.port.NNTP}' name='nntp'/>
+ <TestProtocol port='${org.apache.james.smoke.port.NNTP}' name='nntp'/>
+
+ <TestDelivery/>
</sequential>
</macrodef>
@@ -204,7 +217,7 @@
<xslt
style="../build-tools/@{style}.xsl"
in='@{dir}/@{conf-path}/@{conf-file-name}'
- out='@{dir}/@{conf-path}/config-smoke.xml'></xslt>
+ out='@{dir}/@{conf-path}/config-smoke.xml'></xslt>
<move
file='@{dir}/@{conf-path}/config-smoke.xml'
tofile="@{dir}/@{conf-path}/@{conf-file-name}"/>
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org