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/02/16 14:33:37 UTC

svn commit: r628293 - in /james/server/trunk/experimental-seda-imap-function/src/test: java/org/apache/james/test/functional/ resources/org/apache/james/test/functional/ resources/org/apache/james/test/functional/imap/scripts/

Author: rdonkin
Date: Sat Feb 16 05:33:36 2008
New Revision: 628293

URL: http://svn.apache.org/viewvc?rev=628293&view=rev
Log:
Some new functional testing scripts for FETCH and the mails I generated them from.

Added:
    james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/CreateScript.java
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartAlternative.test
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixed.test
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixedComplex.test
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartAlternative.test
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixed.test
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixedComplex.test
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-alt.mail
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed-complex.mail
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed.mail
    james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/rfc822.mail
Modified:
    james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/ScriptBuilder.java

Added: james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/CreateScript.java
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/CreateScript.java?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/CreateScript.java (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/CreateScript.java Sat Feb 16 05:33:36 2008
@@ -0,0 +1,111 @@
+/****************************************************************
+ * Licensed to the Apache Software Foundation (ASF) under one   *
+ * or more contributor license agreements.  See the NOTICE file *
+ * distributed with this work for additional information        *
+ * regarding copyright ownership.  The ASF licenses this file   *
+ * to you under the Apache License, Version 2.0 (the            *
+ * "License"); you may not use this file except in compliance   *
+ * with the License.  You may obtain a copy of the License at   *
+ *                                                              *
+ *   http://www.apache.org/licenses/LICENSE-2.0                 *
+ *                                                              *
+ * Unless required by applicable law or agreed to in writing,   *
+ * software distributed under the License is distributed on an  *
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       *
+ * KIND, either express or implied.  See the License for the    *
+ * specific language governing permissions and limitations      *
+ * under the License.                                           *
+ ****************************************************************/
+
+package org.apache.james.test.functional;
+
+public class CreateScript {
+
+    public static final void main(String[] args) throws Exception {
+        ScriptBuilder builder = ScriptBuilder.open("localhost", 143);
+        multipartMixedMessagesPeek(builder);
+    }
+    
+
+    public static void multipartMixedMessagesPeek(ScriptBuilder builder) throws Exception {
+        builder.setPeek(true);
+        multipartMixedMessages(builder);
+    }
+    
+    public static void multipartMixedMessages(ScriptBuilder builder) throws Exception {
+        builder.login();
+        builder.create();
+        builder.select();
+        builder.setFile("multipart-mixed-complex.mail");
+        builder.append();
+        builder.select();
+        builder.fetchSection("");
+        builder.fetchSection("TEXT");
+        builder.fetchSection("HEADER");
+        builder.fetchSection("1");
+        builder.fetchSection("2");
+        builder.fetchSection("3");
+        builder.fetchSection("3.HEADER");
+        builder.fetchSection("3.TEXT");
+        builder.fetchSection("3.1");
+        builder.fetchSection("3.2");
+        builder.fetchSection("4");
+        builder.fetchSection("4.1");
+        builder.fetchSection("4.1.MIME");
+        builder.fetchSection("4.2");
+        builder.fetchSection("4.2.HEADER");
+        builder.fetchSection("4.2.TEXT");
+        builder.fetchSection("4.2.1");
+        builder.fetchSection("4.2.2");
+        builder.fetchSection("4.2.2.1");
+        builder.fetchSection("4.2.2.2");
+        builder.select();
+        builder.quit();
+    }
+    
+    public static void multipartAlternativePeek(ScriptBuilder builder) throws Exception {
+        builder.setPeek(true);
+        multipartAlternative(builder);
+    }
+    
+    public static void multipartAlternative(ScriptBuilder builder) throws Exception {
+        builder.login();
+        builder.create();
+        builder.select();
+        builder.setFile("multipart-alt.mail");
+        builder.append();
+        builder.select();
+        builder.fetchSection("");
+        builder.fetchSection("TEXT");
+        builder.fetchSection("HEADER");
+        builder.fetchSection("1");
+        builder.fetchSection("2");
+        builder.fetchSection("3");
+        builder.select();
+        builder.quit();
+    }
+    
+    public static void multipartMixedPeek(ScriptBuilder builder) throws Exception {
+        builder.setPeek(true);
+        multipartMixed(builder);
+    }
+    
+    public static void multipartMixed(ScriptBuilder builder) throws Exception {
+        builder.login();
+        builder.create();
+        builder.select();
+        builder.setFile("multipart-mixed.mail");
+        builder.append();
+        builder.select();
+        builder.fetchSection("");
+        builder.fetchSection("TEXT");
+        builder.fetchSection("HEADER");
+        builder.fetchSection("1");
+        builder.fetchSection("2");
+        builder.fetchSection("3");
+        builder.fetchSection("4");
+        builder.select();
+        builder.quit();
+    }
+    
+}

Modified: james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/ScriptBuilder.java
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/ScriptBuilder.java?rev=628293&r1=628292&r2=628293&view=diff
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/ScriptBuilder.java (original)
+++ james/server/trunk/experimental-seda-imap-function/src/test/java/org/apache/james/test/functional/ScriptBuilder.java Sat Feb 16 05:33:36 2008
@@ -43,6 +43,7 @@
     
     private int tagCount = 0;
     
+    private boolean peek = false;
     private int messageNumber = 1;
     private String user = "imapuser";
     private String password = "password";
@@ -58,6 +59,14 @@
         this.client = client;
     }
     
+    public final boolean isPeek() {
+        return peek;
+    }
+
+    public final void setPeek(boolean peek) {
+        this.peek = peek;
+    }
+
     public final String getBasedir() {
         return basedir;
     }
@@ -76,7 +85,7 @@
     
     private InputStream openFile() throws Exception {
         InputStream result = this.getClass().getResourceAsStream( basedir + file );
-        return result;
+        return new IgnoreHeaderInputStream(result);
     }
     
     public final int getMessageNumber() {
@@ -138,7 +147,14 @@
     }
     
     public void fetchSection(String section) throws Exception {
-        command("FETCH " + messageNumber + " (BODY[" + section + "])");
+        final String body;
+        if (peek) {
+            body = " (BODY.PEEK[";
+        } else {
+            body = " (BODY[";
+        }
+        final String command = "FETCH " + messageNumber + body + section + "])";
+        command(command);
     }
     
     public void append() throws Exception {
@@ -148,7 +164,7 @@
         lineEnd();
         response();
     }
-    
+
     private void write(InputStream in) throws Exception {
         client.write(in);
     }
@@ -315,9 +331,7 @@
         }
         
         private void readLine() throws Exception {
-            print('S');
-            print(':');
-            print(' ');
+            out.server();
             
             final byte next = next();
             isLineTagged = next != '*';
@@ -414,20 +428,87 @@
         }
         
         public void print(char next) {
+            if (!isClient) {
+                escape(next);
+            }
             System.out.print(next);
         }
 
+        private void escape(char next) {
+            if (next == '\\' || next == '*' || next=='.' || next == '[' || next == ']' || next == '+'
+                || next == '(' || next == ')') {
+                System.out.print('\\');
+            }
+        }
+
         public void server() {
             System.out.print("S: ");
             isClient = false;
         }
         
         public void print(String phrase) {
+            if (!isClient) {
+                phrase = StringUtils.replace(phrase, "\\", "\\\\");
+                phrase = StringUtils.replace(phrase, "*", "\\*");
+                phrase = StringUtils.replace(phrase, ".", "\\.");
+                phrase = StringUtils.replace(phrase, "[", "\\[");
+                phrase = StringUtils.replace(phrase, "]", "\\]");
+                phrase = StringUtils.replace(phrase, "+", "\\+");
+                phrase = StringUtils.replace(phrase, "(", "\\(");
+                phrase = StringUtils.replace(phrase, ")", "\\)");
+            }
             System.out.print(phrase);
         }
         
         public void lineEnd() {
             System.out.println();
+        }
+    }
+    
+    private static final class IgnoreHeaderInputStream extends InputStream {
+
+        private boolean isFinishedHeaders = false;
+        private final InputStream delegate;
+        
+        public IgnoreHeaderInputStream(final InputStream delegate) {
+            super();
+            this.delegate = delegate;
+        }
+
+        public int read() throws IOException {
+            final int result;
+            final int next = delegate.read();
+            if (isFinishedHeaders) {
+                result = next;
+            } else {
+                switch (next) {
+                    case -1:
+                        isFinishedHeaders = true;
+                        result = next;
+                        break;
+                    case '#':
+                        readLine();
+                        result = read();
+                        break;
+                        
+                    case '\r':
+                    case '\n':
+                        result = read();
+                        break;
+                        
+                    default:
+                        isFinishedHeaders = true;
+                        result = next;
+                        break;
+                }
+            }
+            return result;
+        }
+        private void readLine() throws IOException {
+            int next = delegate.read();
+            while (next != -1 && next !='\r' && next !='\n') {
+                next = delegate.read();
+            }
         }
     }
 }

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartAlternative.test
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartAlternative.test?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartAlternative.test (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartAlternative.test Sat Feb 16 05:33:36 2008
@@ -0,0 +1,160 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+C: A2 CREATE testmailbox
+S: A2 OK Create completed\.
+C: A3 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 0 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163874\] UIDs valid
+S: \* OK \[UIDNEXT 1\] Predicted next UID
+S: A3 OK \[READ-WRITE\] Select completed\.
+C: A4 APPEND testmailbox {666+}
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Email
+C: Content-Type: multipart/alternative;boundary=1729
+C: 
+C: Start with a preamble
+C: 
+C: --1729
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Rhubarb!
+C: 
+C: --1729
+C: Content-Type: text/html; charset=US-ASCII
+C: 
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: 
+C: --1729
+C: Content-Type: applcation/xhtml+xml
+C: 
+C: <!DOCTYPE html
+C: PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+C: "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: --1729--
+C: 
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: A4 OK Append completed\.
+C: A5 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163874\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A5 OK \[READ-WRITE\] Select completed\.
+C: A6 FETCH 1 (BODY[])
+S: \* 1 FETCH \(FLAGS \(\\Seen \\Recent\) BODY\[\] {666}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/alternative;boundary=1729
+S: 
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: applcation/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: --1729--
+S: \)
+S: A6 OK Fetch completed\.
+C: A7 FETCH 1 (BODY[TEXT])
+S: \* 1 FETCH \(BODY\[TEXT\] {457}
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: applcation/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: --1729--
+S: \)
+S: A7 OK Fetch completed\.
+C: A8 FETCH 1 (BODY[HEADER])
+S: \* 1 FETCH \(BODY\[HEADER\] {209}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/alternative;boundary=1729
+S: 
+S: \)
+S: A8 OK Fetch completed\.
+C: A9 FETCH 1 (BODY[1])
+S: \* 1 FETCH \(BODY\[1\] {10}
+S: Rhubarb!
+S: \)
+S: A9 OK Fetch completed\.
+C: A10 FETCH 1 (BODY[2])
+S: \* 1 FETCH \(BODY\[2\] {71}
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: \)
+S: A10 OK Fetch completed\.
+C: A11 FETCH 1 (BODY[3])
+S: \* 1 FETCH \(BODY\[3\] {182}
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>\)
+S: A11 OK Fetch completed\.
+C: A12 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163874\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A12 OK \[READ-WRITE\] Select completed\.
+C: A13 DELETE testmailbox
+S: A13 OK Delete completed\.

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixed.test
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixed.test?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixed.test (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixed.test Sat Feb 16 05:33:36 2008
@@ -0,0 +1,187 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+C: A2 CREATE testmailbox
+S: A2 OK Create completed\.
+C: A3 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 0 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163839\] UIDs valid
+S: \* OK \[UIDNEXT 1\] Predicted next UID
+S: A3 OK \[READ-WRITE\] Select completed\.
+C: A4 APPEND testmailbox {765+}
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Email
+C: Content-Type: multipart/mixed;boundary=1729
+C: 
+C: Start with a preamble
+C: 
+C: --1729
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Rhubarb!
+C: 
+C: --1729
+C: Content-Type: text/html; charset=US-ASCII
+C: 
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: 
+C: --1729
+C: Content-Type: application/xhtml+xml
+C: 
+C: <!DOCTYPE html
+C: PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+C: "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: 
+C: --1729
+C: Content-Type: image/jpeg
+C: Content-Transfer-Encoding: base64
+C: 
+C: 1234567890ABCDEFGHIJKLMNOPQ
+C: 
+C: --1729--
+C: 
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: A4 OK Append completed\.
+C: A5 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163839\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A5 OK \[READ-WRITE\] Select completed\.
+C: A6 FETCH 1 (BODY[])
+S: \* 1 FETCH \(FLAGS \(\\Seen \\Recent\) BODY\[\] {765}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: application/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: image/jpeg
+S: Content-Transfer-Encoding: base64
+S: 
+S: 1234567890ABCDEFGHIJKLMNOPQ
+S: 
+S: --1729--
+S: \)
+S: A6 OK Fetch completed\.
+C: A7 FETCH 1 (BODY[TEXT])
+S: \* 1 FETCH \(BODY\[TEXT\] {562}
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: application/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: image/jpeg
+S: Content-Transfer-Encoding: base64
+S: 
+S: 1234567890ABCDEFGHIJKLMNOPQ
+S: 
+S: --1729--
+S: \)
+S: A7 OK Fetch completed\.
+C: A8 FETCH 1 (BODY[HEADER])
+S: \* 1 FETCH \(BODY\[HEADER\] {203}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: \)
+S: A8 OK Fetch completed\.
+C: A9 FETCH 1 (BODY[1])
+S: \* 1 FETCH \(BODY\[1\] {10}
+S: Rhubarb!
+S: \)
+S: A9 OK Fetch completed\.
+C: A10 FETCH 1 (BODY[2])
+S: \* 1 FETCH \(BODY\[2\] {71}
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: \)
+S: A10 OK Fetch completed\.
+C: A11 FETCH 1 (BODY[3])
+S: \* 1 FETCH \(BODY\[3\] {184}
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: \)
+S: A11 OK Fetch completed\.
+C: A12 FETCH 1 (BODY[4])
+S: \* 1 FETCH \(BODY\[4\] {29}
+S: 1234567890ABCDEFGHIJKLMNOPQ
+S: \)
+S: A12 OK Fetch completed\.
+C: A13 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163839\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A13 OK \[READ-WRITE\] Select completed\.
+C: A14 DELETE testmailbox
+S: A14 OK Delete completed\.

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixedComplex.test
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixedComplex.test?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixedComplex.test (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/FetchMultipartMixedComplex.test Sat Feb 16 05:33:36 2008
@@ -0,0 +1,572 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+C: A2 CREATE testmailbox
+S: A2 OK Create completed\.
+C: A3 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 0 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163795\] UIDs valid
+S: \* OK \[UIDNEXT 1\] Predicted next UID
+S: A3 OK \[READ-WRITE\] Select completed\.
+C: A4 APPEND testmailbox {1767+}
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Email
+C: Content-Type: multipart/mixed;boundary=1729
+C: 
+C: Start with a preamble
+C: 
+C: --1729
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Rhubarb!
+C: 
+C: --1729
+C: Content-Type: application/octet-stream
+C: Content-Transfer-Encoding: base64
+C: 
+C: 987654321AHPLA
+C: 
+C: --1729
+C: Content-Type: message/rfc822
+C: 
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Alternative Email
+C: Content-Type: multipart/alternative;boundary=42
+C: 
+C: This message has a premable
+C: 
+C: --42
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Custard!
+C: 
+C: --42
+C: Content-Type: application/octet-stream
+C: 
+C: CUSTARDCUSTARDCUSTARD
+C: 
+C: --42--
+C: 
+C: --1729
+C: Content-Type: multipart/mixed; boundary=4.66920160910299
+C: 
+C: --4.66920160910299
+C: Content-Type: image/gif
+C: Content-Transfer-Encoding: base64
+C: MIME-Version: 1.0
+C: Content-ID: 238478934723847238947892374
+C: Content-Description: Bogus Image Data
+C: 
+C: ABCDFEGHIJKLMNO
+C: 
+C: --4.66920160910299
+C: Content-Type: message/rfc822
+C: 
+C: From: Timothy Tayler <ti...@example.org>
+C: To: John Smith <jo...@example.org>
+C: Date: Sat, 16 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: Another Example Email
+C: Content-Type: multipart/mixed;boundary=2.50290787509
+C: 
+C: Yet another preamble
+C: 
+C: --2.50290787509
+C: Content-Type: text/plain
+C: 
+C: Rhubard AND Custard!
+C: 
+C: --2.50290787509
+C: Content-Type: multipart/alternative;boundary=3.243F6A8885A308D3
+C: 
+C: --3.243F6A8885A308D3
+C: Content-Type: text/plain
+C: 
+C: Rhubard?Custard?
+C: 
+C: --3.243F6A8885A308D3
+C: 
+C: Content-Type: text/richtext
+C: 
+C: Rhubard?Custard?
+C: 
+C: --3.243F6A8885A308D3--
+C: 
+C: --2.50290787509--
+C: 
+C: --4.66920160910299--
+C: --1729--
+C: 
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: A4 OK Append completed\.
+C: A5 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163795\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A5 OK \[READ-WRITE\] Select completed\.
+C: A6 FETCH 1 (BODY[])
+S: \* 1 FETCH \(FLAGS \(\\Seen \\Recent\) BODY\[\] {1767}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: application/octet-stream
+S: Content-Transfer-Encoding: base64
+S: 
+S: 987654321AHPLA
+S: 
+S: --1729
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: 
+S: --1729
+S: Content-Type: multipart/mixed; boundary=4\.66920160910299
+S: 
+S: --4\.66920160910299
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: ABCDFEGHIJKLMNO
+S: 
+S: --4\.66920160910299
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: 
+S: --4\.66920160910299--
+S: --1729--
+S: \)
+S: A6 OK Fetch completed\.
+C: A7 FETCH 1 (BODY[TEXT])
+S: \* 1 FETCH \(BODY\[TEXT\] {1564}
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: application/octet-stream
+S: Content-Transfer-Encoding: base64
+S: 
+S: 987654321AHPLA
+S: 
+S: --1729
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: 
+S: --1729
+S: Content-Type: multipart/mixed; boundary=4\.66920160910299
+S: 
+S: --4\.66920160910299
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: ABCDFEGHIJKLMNO
+S: 
+S: --4\.66920160910299
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: 
+S: --4\.66920160910299--
+S: --1729--
+S: \)
+S: A7 OK Fetch completed\.
+C: A8 FETCH 1 (BODY[HEADER])
+S: \* 1 FETCH \(BODY\[HEADER\] {203}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: \)
+S: A8 OK Fetch completed\.
+C: A9 FETCH 1 (BODY[1])
+S: \* 1 FETCH \(BODY\[1\] {10}
+S: Rhubarb!
+S: \)
+S: A9 OK Fetch completed\.
+C: A10 FETCH 1 (BODY[2])
+S: \* 1 FETCH \(BODY\[2\] {16}
+S: 987654321AHPLA
+S: \)
+S: A10 OK Fetch completed\.
+C: A11 FETCH 1 (BODY[3])
+S: \* 1 FETCH \(BODY\[3\] {395}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: \)
+S: A11 OK Fetch completed\.
+C: A12 FETCH 1 (BODY[3.HEADER])
+S: \* 1 FETCH \(BODY\[3\.HEADER\] {219}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: \)
+S: A12 OK Fetch completed\.
+C: A13 FETCH 1 (BODY[3.TEXT])
+S: \* 1 FETCH \(BODY\[3\.TEXT\] {176}
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: \)
+S: A13 OK Fetch completed\.
+C: A14 FETCH 1 (BODY[3.1])
+S: \* 1 FETCH \(BODY\[3\.1\] {10}
+S: Custard!
+S: \)
+S: A14 OK Fetch completed\.
+C: A15 FETCH 1 (BODY[3.2])
+S: \* 1 FETCH \(BODY\[3\.2\] {23}
+S: CUSTARDCUSTARDCUSTARD
+S: \)
+S: A15 OK Fetch completed\.
+C: A16 FETCH 1 (BODY[4])
+S: \* 1 FETCH \(BODY\[4\] {853}
+S: --4\.66920160910299
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: ABCDFEGHIJKLMNO
+S: 
+S: --4\.66920160910299
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: 
+S: --4\.66920160910299--\)
+S: A16 OK Fetch completed\.
+C: A17 FETCH 1 (BODY[4.1])
+S: \* 1 FETCH \(BODY\[4\.1\] {17}
+S: ABCDFEGHIJKLMNO
+S: \)
+S: A17 OK Fetch completed\.
+C: A18 FETCH 1 (BODY[4.1.MIME])
+S: \* 1 FETCH \(BODY\[4\.1\.MIME\] {161}
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: \)
+S: A18 OK Fetch completed\.
+C: A19 FETCH 1 (BODY[4.2])
+S: \* 1 FETCH \(BODY\[4\.2\] {579}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: \)
+S: A19 OK Fetch completed\.
+C: A20 FETCH 1 (BODY[4.2.HEADER])
+S: \* 1 FETCH \(BODY\[4\.2\.HEADER\] {212}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: \)
+S: A20 OK Fetch completed\.
+C: A21 FETCH 1 (BODY[4.2.TEXT])
+S: \* 1 FETCH \(BODY\[4\.2\.TEXT\] {367}
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: \)
+S: A21 OK Fetch completed\.
+C: A22 FETCH 1 (BODY[4.2.1])
+S: \* 1 FETCH \(BODY\[4\.2\.1\] {22}
+S: Rhubard AND Custard!
+S: \)
+S: A22 OK Fetch completed\.
+C: A23 FETCH 1 (BODY[4.2.2])
+S: \* 1 FETCH \(BODY\[4\.2\.2\] {169}
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: \)
+S: A23 OK Fetch completed\.
+C: A24 FETCH 1 (BODY[4.2.2.1])
+S: \* 1 FETCH \(BODY\[4\.2\.2\.1\] {18}
+S: Rhubard?Custard?
+S: \)
+S: A24 OK Fetch completed\.
+C: A25 FETCH 1 (BODY[4.2.2.2])
+S: \* 1 FETCH \(BODY\[4\.2\.2\.2\] {49}
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: \)
+S: A25 OK Fetch completed\.
+C: A26 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163795\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A26 OK \[READ-WRITE\] Select completed\.
+C: A27 DELETE testmailbox
+S: A27 OK Delete completed\.

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartAlternative.test
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartAlternative.test?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartAlternative.test (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartAlternative.test Sat Feb 16 05:33:36 2008
@@ -0,0 +1,161 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+C: A2 CREATE testmailbox
+S: A2 OK Create completed\.
+C: A3 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 0 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163909\] UIDs valid
+S: \* OK \[UIDNEXT 1\] Predicted next UID
+S: A3 OK \[READ-WRITE\] Select completed\.
+C: A4 APPEND testmailbox {666+}
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Email
+C: Content-Type: multipart/alternative;boundary=1729
+C: 
+C: Start with a preamble
+C: 
+C: --1729
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Rhubarb!
+C: 
+C: --1729
+C: Content-Type: text/html; charset=US-ASCII
+C: 
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: 
+C: --1729
+C: Content-Type: applcation/xhtml+xml
+C: 
+C: <!DOCTYPE html
+C: PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+C: "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: --1729--
+C: 
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: A4 OK Append completed\.
+C: A5 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163909\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A5 OK \[READ-WRITE\] Select completed\.
+C: A6 FETCH 1 (BODY.PEEK[])
+S: \* 1 FETCH \(BODY\[\] {666}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/alternative;boundary=1729
+S: 
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: applcation/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: --1729--
+S: \)
+S: A6 OK Fetch completed\.
+C: A7 FETCH 1 (BODY.PEEK[TEXT])
+S: \* 1 FETCH \(BODY\[TEXT\] {457}
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: applcation/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: --1729--
+S: \)
+S: A7 OK Fetch completed\.
+C: A8 FETCH 1 (BODY.PEEK[HEADER])
+S: \* 1 FETCH \(BODY\[HEADER\] {209}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/alternative;boundary=1729
+S: 
+S: \)
+S: A8 OK Fetch completed\.
+C: A9 FETCH 1 (BODY.PEEK[1])
+S: \* 1 FETCH \(BODY\[1\] {10}
+S: Rhubarb!
+S: \)
+S: A9 OK Fetch completed\.
+C: A10 FETCH 1 (BODY.PEEK[2])
+S: \* 1 FETCH \(BODY\[2\] {71}
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: \)
+S: A10 OK Fetch completed\.
+C: A11 FETCH 1 (BODY.PEEK[3])
+S: \* 1 FETCH \(BODY\[3\] {182}
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>\)
+S: A11 OK Fetch completed\.
+C: A12 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163909\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A12 OK \[READ-WRITE\] Select completed\.
+C: A13 DELETE testmailbox
+S: A13 OK Delete completed\.

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixed.test
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixed.test?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixed.test (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixed.test Sat Feb 16 05:33:36 2008
@@ -0,0 +1,188 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+C: A2 CREATE testmailbox
+S: A2 OK Create completed\.
+C: A3 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 0 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163935\] UIDs valid
+S: \* OK \[UIDNEXT 1\] Predicted next UID
+S: A3 OK \[READ-WRITE\] Select completed\.
+C: A4 APPEND testmailbox {765+}
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Email
+C: Content-Type: multipart/mixed;boundary=1729
+C: 
+C: Start with a preamble
+C: 
+C: --1729
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Rhubarb!
+C: 
+C: --1729
+C: Content-Type: text/html; charset=US-ASCII
+C: 
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: 
+C: --1729
+C: Content-Type: application/xhtml+xml
+C: 
+C: <!DOCTYPE html
+C: PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+C: "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+C: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+C: 
+C: --1729
+C: Content-Type: image/jpeg
+C: Content-Transfer-Encoding: base64
+C: 
+C: 1234567890ABCDEFGHIJKLMNOPQ
+C: 
+C: --1729--
+C: 
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: A4 OK Append completed\.
+C: A5 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163935\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A5 OK \[READ-WRITE\] Select completed\.
+C: A6 FETCH 1 (BODY.PEEK[])
+S: \* 1 FETCH \(BODY\[\] {765}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: application/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: image/jpeg
+S: Content-Transfer-Encoding: base64
+S: 
+S: 1234567890ABCDEFGHIJKLMNOPQ
+S: 
+S: --1729--
+S: \)
+S: A6 OK Fetch completed\.
+C: A7 FETCH 1 (BODY.PEEK[TEXT])
+S: \* 1 FETCH \(BODY\[TEXT\] {562}
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: text/html; charset=US-ASCII
+S: 
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: application/xhtml\+xml
+S: 
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: 
+S: --1729
+S: Content-Type: image/jpeg
+S: Content-Transfer-Encoding: base64
+S: 
+S: 1234567890ABCDEFGHIJKLMNOPQ
+S: 
+S: --1729--
+S: \)
+S: A7 OK Fetch completed\.
+C: A8 FETCH 1 (BODY.PEEK[HEADER])
+S: \* 1 FETCH \(BODY\[HEADER\] {203}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: \)
+S: A8 OK Fetch completed\.
+C: A9 FETCH 1 (BODY.PEEK[1])
+S: \* 1 FETCH \(BODY\[1\] {10}
+S: Rhubarb!
+S: \)
+S: A9 OK Fetch completed\.
+C: A10 FETCH 1 (BODY.PEEK[2])
+S: \* 1 FETCH \(BODY\[2\] {71}
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: \)
+S: A10 OK Fetch completed\.
+C: A11 FETCH 1 (BODY.PEEK[3])
+S: \* 1 FETCH \(BODY\[3\] {184}
+S: <!DOCTYPE html
+S: PUBLIC "-//W3C//DTD XHTML 1\.0 Strict//EN"
+S: "http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-strict\.dtd">
+S: <html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+S: \)
+S: A11 OK Fetch completed\.
+C: A12 FETCH 1 (BODY.PEEK[4])
+S: \* 1 FETCH \(BODY\[4\] {29}
+S: 1234567890ABCDEFGHIJKLMNOPQ
+S: \)
+S: A12 OK Fetch completed\.
+C: A13 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163935\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A13 OK \[READ-WRITE\] Select completed\.
+C: A14 DELETE testmailbox
+S: A14 OK Delete completed\.

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixedComplex.test
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixedComplex.test?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixedComplex.test (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/imap/scripts/PeekMultipartMixedComplex.test Sat Feb 16 05:33:36 2008
@@ -0,0 +1,573 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+C: A2 CREATE testmailbox
+S: A2 OK Create completed\.
+C: A3 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 0 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UIDVALIDITY 1203163973\] UIDs valid
+S: \* OK \[UIDNEXT 1\] Predicted next UID
+S: A3 OK \[READ-WRITE\] Select completed\.
+C: A4 APPEND testmailbox {1767+}
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Email
+C: Content-Type: multipart/mixed;boundary=1729
+C: 
+C: Start with a preamble
+C: 
+C: --1729
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Rhubarb!
+C: 
+C: --1729
+C: Content-Type: application/octet-stream
+C: Content-Transfer-Encoding: base64
+C: 
+C: 987654321AHPLA
+C: 
+C: --1729
+C: Content-Type: message/rfc822
+C: 
+C: From: Timothy Tayler <ti...@example.org>
+C: To: Samual Smith <sa...@example.org>
+C: Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: A Multipart Alternative Email
+C: Content-Type: multipart/alternative;boundary=42
+C: 
+C: This message has a premable
+C: 
+C: --42
+C: Content-Type: text/plain; charset=US-ASCII
+C: 
+C: Custard!
+C: 
+C: --42
+C: Content-Type: application/octet-stream
+C: 
+C: CUSTARDCUSTARDCUSTARD
+C: 
+C: --42--
+C: 
+C: --1729
+C: Content-Type: multipart/mixed; boundary=4.66920160910299
+C: 
+C: --4.66920160910299
+C: Content-Type: image/gif
+C: Content-Transfer-Encoding: base64
+C: MIME-Version: 1.0
+C: Content-ID: 238478934723847238947892374
+C: Content-Description: Bogus Image Data
+C: 
+C: ABCDFEGHIJKLMNO
+C: 
+C: --4.66920160910299
+C: Content-Type: message/rfc822
+C: 
+C: From: Timothy Tayler <ti...@example.org>
+C: To: John Smith <jo...@example.org>
+C: Date: Sat, 16 Feb 2008 12:00:00 +0000 (GMT)
+C: Subject: Another Example Email
+C: Content-Type: multipart/mixed;boundary=2.50290787509
+C: 
+C: Yet another preamble
+C: 
+C: --2.50290787509
+C: Content-Type: text/plain
+C: 
+C: Rhubard AND Custard!
+C: 
+C: --2.50290787509
+C: Content-Type: multipart/alternative;boundary=3.243F6A8885A308D3
+C: 
+C: --3.243F6A8885A308D3
+C: Content-Type: text/plain
+C: 
+C: Rhubard?Custard?
+C: 
+C: --3.243F6A8885A308D3
+C: 
+C: Content-Type: text/richtext
+C: 
+C: Rhubard?Custard?
+C: 
+C: --3.243F6A8885A308D3--
+C: 
+C: --2.50290787509--
+C: 
+C: --4.66920160910299--
+C: --1729--
+C: 
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: A4 OK Append completed\.
+C: A5 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 1 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163973\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A5 OK \[READ-WRITE\] Select completed\.
+C: A6 FETCH 1 (BODY.PEEK[])
+S: \* 1 FETCH \(BODY\[\] {1767}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: application/octet-stream
+S: Content-Transfer-Encoding: base64
+S: 
+S: 987654321AHPLA
+S: 
+S: --1729
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: 
+S: --1729
+S: Content-Type: multipart/mixed; boundary=4\.66920160910299
+S: 
+S: --4\.66920160910299
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: ABCDFEGHIJKLMNO
+S: 
+S: --4\.66920160910299
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: 
+S: --4\.66920160910299--
+S: --1729--
+S: \)
+S: A6 OK Fetch completed\.
+C: A7 FETCH 1 (BODY.PEEK[TEXT])
+S: \* 1 FETCH \(BODY\[TEXT\] {1564}
+S: Start with a preamble
+S: 
+S: --1729
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Rhubarb!
+S: 
+S: --1729
+S: Content-Type: application/octet-stream
+S: Content-Transfer-Encoding: base64
+S: 
+S: 987654321AHPLA
+S: 
+S: --1729
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: 
+S: --1729
+S: Content-Type: multipart/mixed; boundary=4\.66920160910299
+S: 
+S: --4\.66920160910299
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: ABCDFEGHIJKLMNO
+S: 
+S: --4\.66920160910299
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: 
+S: --4\.66920160910299--
+S: --1729--
+S: \)
+S: A7 OK Fetch completed\.
+C: A8 FETCH 1 (BODY.PEEK[HEADER])
+S: \* 1 FETCH \(BODY\[HEADER\] {203}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Email
+S: Content-Type: multipart/mixed;boundary=1729
+S: 
+S: \)
+S: A8 OK Fetch completed\.
+C: A9 FETCH 1 (BODY.PEEK[1])
+S: \* 1 FETCH \(BODY\[1\] {10}
+S: Rhubarb!
+S: \)
+S: A9 OK Fetch completed\.
+C: A10 FETCH 1 (BODY.PEEK[2])
+S: \* 1 FETCH \(BODY\[2\] {16}
+S: 987654321AHPLA
+S: \)
+S: A10 OK Fetch completed\.
+C: A11 FETCH 1 (BODY.PEEK[3])
+S: \* 1 FETCH \(BODY\[3\] {395}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: \)
+S: A11 OK Fetch completed\.
+C: A12 FETCH 1 (BODY.PEEK[3.HEADER])
+S: \* 1 FETCH \(BODY\[3\.HEADER\] {219}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: Samual Smith <samual@example\.org>
+S: Date: Thu, 14 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: A Multipart Alternative Email
+S: Content-Type: multipart/alternative;boundary=42
+S: 
+S: \)
+S: A12 OK Fetch completed\.
+C: A13 FETCH 1 (BODY.PEEK[3.TEXT])
+S: \* 1 FETCH \(BODY\[3\.TEXT\] {176}
+S: This message has a premable
+S: 
+S: --42
+S: Content-Type: text/plain; charset=US-ASCII
+S: 
+S: Custard!
+S: 
+S: --42
+S: Content-Type: application/octet-stream
+S: 
+S: CUSTARDCUSTARDCUSTARD
+S: 
+S: --42--
+S: \)
+S: A13 OK Fetch completed\.
+C: A14 FETCH 1 (BODY.PEEK[3.1])
+S: \* 1 FETCH \(BODY\[3\.1\] {10}
+S: Custard!
+S: \)
+S: A14 OK Fetch completed\.
+C: A15 FETCH 1 (BODY.PEEK[3.2])
+S: \* 1 FETCH \(BODY\[3\.2\] {23}
+S: CUSTARDCUSTARDCUSTARD
+S: \)
+S: A15 OK Fetch completed\.
+C: A16 FETCH 1 (BODY.PEEK[4])
+S: \* 1 FETCH \(BODY\[4\] {853}
+S: --4\.66920160910299
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: ABCDFEGHIJKLMNO
+S: 
+S: --4\.66920160910299
+S: Content-Type: message/rfc822
+S: 
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: 
+S: --4\.66920160910299--\)
+S: A16 OK Fetch completed\.
+C: A17 FETCH 1 (BODY.PEEK[4.1])
+S: \* 1 FETCH \(BODY\[4\.1\] {17}
+S: ABCDFEGHIJKLMNO
+S: \)
+S: A17 OK Fetch completed\.
+C: A18 FETCH 1 (BODY.PEEK[4.1.MIME])
+S: \* 1 FETCH \(BODY\[4\.1\.MIME\] {161}
+S: Content-Type: image/gif
+S: Content-Transfer-Encoding: base64
+S: MIME-Version: 1\.0
+S: Content-ID: 238478934723847238947892374
+S: Content-Description: Bogus Image Data
+S: 
+S: \)
+S: A18 OK Fetch completed\.
+C: A19 FETCH 1 (BODY.PEEK[4.2])
+S: \* 1 FETCH \(BODY\[4\.2\] {579}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: \)
+S: A19 OK Fetch completed\.
+C: A20 FETCH 1 (BODY.PEEK[4.2.HEADER])
+S: \* 1 FETCH \(BODY\[4\.2\.HEADER\] {212}
+S: From: Timothy Tayler <timothy@example\.org>
+S: To: John Smith <john@example\.org>
+S: Date: Sat, 16 Feb 2008 12:00:00 \+0000 \(GMT\)
+S: Subject: Another Example Email
+S: Content-Type: multipart/mixed;boundary=2\.50290787509
+S: 
+S: \)
+S: A20 OK Fetch completed\.
+C: A21 FETCH 1 (BODY.PEEK[4.2.TEXT])
+S: \* 1 FETCH \(BODY\[4\.2\.TEXT\] {367}
+S: Yet another preamble
+S: 
+S: --2\.50290787509
+S: Content-Type: text/plain
+S: 
+S: Rhubard AND Custard!
+S: 
+S: --2\.50290787509
+S: Content-Type: multipart/alternative;boundary=3\.243F6A8885A308D3
+S: 
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: 
+S: --2\.50290787509--
+S: \)
+S: A21 OK Fetch completed\.
+C: A22 FETCH 1 (BODY.PEEK[4.2.1])
+S: \* 1 FETCH \(BODY\[4\.2\.1\] {22}
+S: Rhubard AND Custard!
+S: \)
+S: A22 OK Fetch completed\.
+C: A23 FETCH 1 (BODY.PEEK[4.2.2])
+S: \* 1 FETCH \(BODY\[4\.2\.2\] {169}
+S: --3\.243F6A8885A308D3
+S: Content-Type: text/plain
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3
+S: 
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: 
+S: --3\.243F6A8885A308D3--
+S: \)
+S: A23 OK Fetch completed\.
+C: A24 FETCH 1 (BODY.PEEK[4.2.2.1])
+S: \* 1 FETCH \(BODY\[4\.2\.2\.1\] {18}
+S: Rhubard?Custard?
+S: \)
+S: A24 OK Fetch completed\.
+C: A25 FETCH 1 (BODY.PEEK[4.2.2.2])
+S: \* 1 FETCH \(BODY\[4\.2\.2\.2\] {49}
+S: Content-Type: text/richtext
+S: 
+S: Rhubard?Custard?
+S: \)
+S: A25 OK Fetch completed\.
+C: A26 SELECT testmailbox
+S: \* FLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft\)
+S: \* OK \[PERMANENTFLAGS \(\\Answered \\Flagged \\Deleted \\Seen \\Draft \\\*\)\] Flags permitted\.
+S: \* 1 EXISTS
+S: \* 0 RECENT
+S: \* OK \[UNSEEN 1\] First unseen\.
+S: \* OK \[UIDVALIDITY 1203163973\] UIDs valid
+S: \* OK \[UIDNEXT 2\] Predicted next UID
+S: A26 OK \[READ-WRITE\] Select completed\.
+C: A27 DELETE testmailbox
+S: A27 OK Delete completed\.

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-alt.mail
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-alt.mail?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-alt.mail (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-alt.mail Sat Feb 16 05:33:36 2008
@@ -0,0 +1,46 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+From: Timothy Tayler <ti...@example.org>
+To: Samual Smith <sa...@example.org>
+Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+Subject: A Multipart Email
+Content-Type: multipart/alternative;boundary=1729
+
+Start with a preamble
+
+--1729
+Content-Type: applcation/xhtml+xml
+
+<!DOCTYPE html
+PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+
+--1729
+Content-Type: text/plain; charset=US-ASCII
+
+Rhubarb!
+
+--1729
+Content-Type: text/html; charset=US-ASCII
+
+<html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+
+--1729--

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed-complex.mail
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed-complex.mail?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed-complex.mail (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed-complex.mail Sat Feb 16 05:33:36 2008
@@ -0,0 +1,109 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+From: Timothy Tayler <ti...@example.org>
+To: Samual Smith <sa...@example.org>
+Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+Subject: A Multipart Email
+Content-Type: multipart/mixed;boundary=1729
+
+Start with a preamble
+
+--1729
+Content-Type: text/plain; charset=US-ASCII
+
+Rhubarb!
+
+--1729
+Content-Type: application/octet-stream
+Content-Transfer-Encoding: base64
+
+987654321AHPLA
+
+--1729
+Content-Type: message/rfc822
+
+From: Timothy Tayler <ti...@example.org>
+To: Samual Smith <sa...@example.org>
+Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+Subject: A Multipart Alternative Email
+Content-Type: multipart/alternative;boundary=42
+
+This message has a premable
+
+--42
+Content-Type: text/plain; charset=US-ASCII
+
+Custard!
+
+--42
+Content-Type: application/octet-stream
+
+CUSTARDCUSTARDCUSTARD
+
+--42--
+
+--1729
+Content-Type: multipart/mixed; boundary=4.66920160910299
+
+--4.66920160910299
+Content-Type: image/gif
+Content-Transfer-Encoding: base64
+MIME-Version: 1.0
+Content-ID: 238478934723847238947892374
+Content-Description: Bogus Image Data
+
+ABCDFEGHIJKLMNO
+
+--4.66920160910299
+Content-Type: message/rfc822
+
+From: Timothy Tayler <ti...@example.org>
+To: John Smith <jo...@example.org>
+Date: Sat, 16 Feb 2008 12:00:00 +0000 (GMT)
+Subject: Another Example Email
+Content-Type: multipart/mixed;boundary=2.50290787509
+
+Yet another preamble
+
+--2.50290787509
+Content-Type: text/plain
+
+Rhubard AND Custard!
+
+--2.50290787509
+Content-Type: multipart/alternative;boundary=3.243F6A8885A308D3
+
+--3.243F6A8885A308D3
+Content-Type: text/plain
+
+Rhubard?Custard?
+
+--3.243F6A8885A308D3
+
+Content-Type: text/richtext
+
+Rhubard?Custard?
+
+--3.243F6A8885A308D3--
+
+--2.50290787509--
+
+--4.66920160910299--
+--1729--

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed.mail
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed.mail?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed.mail (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/multipart-mixed.mail Sat Feb 16 05:33:36 2008
@@ -0,0 +1,52 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+From: Timothy Tayler <ti...@example.org>
+To: Samual Smith <sa...@example.org>
+Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+Subject: A Multipart Email
+Content-Type: multipart/mixed;boundary=1729
+
+Start with a preamble
+
+--1729
+Content-Type: text/plain; charset=US-ASCII
+
+Rhubarb!
+
+--1729
+Content-Type: text/html; charset=US-ASCII
+
+<html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+
+--1729
+Content-Type: application/xhtml+xml
+
+<!DOCTYPE html
+PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html><head><title>Rhubarb</title></head><body>Rhubarb!</body></html>
+
+--1729
+Content-Type: image/jpeg
+Content-Transfer-Encoding: base64
+
+1234567890ABCDEFGHIJKLMNOPQ
+
+--1729--

Added: james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/rfc822.mail
URL: http://svn.apache.org/viewvc/james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/rfc822.mail?rev=628293&view=auto
==============================================================================
--- james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/rfc822.mail (added)
+++ james/server/trunk/experimental-seda-imap-function/src/test/resources/org/apache/james/test/functional/rfc822.mail Sat Feb 16 05:33:36 2008
@@ -0,0 +1,25 @@
+################################################################
+# Licensed to the Apache Software Foundation (ASF) under one   #
+# or more contributor license agreements.  See the NOTICE file #
+# distributed with this work for additional information        #
+# regarding copyright ownership.  The ASF licenses this file   #
+# to you under the Apache License, Version 2.0 (the            #
+# "License"); you may not use this file except in compliance   #
+# with the License.  You may obtain a copy of the License at   #
+#                                                              #
+#   http://www.apache.org/licenses/LICENSE-2.0                 #
+#                                                              #
+# Unless required by applicable law or agreed to in writing,   #
+# software distributed under the License is distributed on an  #
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       #
+# KIND, either express or implied.  See the License for the    #
+# specific language governing permissions and limitations      #
+# under the License.                                           #
+################################################################
+
+From: Timothy Tayler <ti...@example.org>
+To: Samual Smith <sa...@example.org>
+Date: Thu, 14 Feb 2008 12:00:00 +0000 (GMT)
+Subject: A Simple Email
+
+This is a very simple email.



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org