james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From darr...@apache.org
Subject cvs commit: james-server/proposals/imap2/test/org/apache/james/imapserver FetchPeek.test FetchSingleMessage.test TestSelectedCommandsInSelectedState.java
Date Tue, 30 Dec 2003 00:24:32 GMT
darrell     2003/12/29 16:24:32

  Modified:    proposals/imap2/test/org/apache/james/imapserver
                        FetchSingleMessage.test
                        TestSelectedCommandsInSelectedState.java
  Added:       proposals/imap2/test/org/apache/james/imapserver
                        FetchPeek.test
  Log:
  Imap2 proposal: tests for FETCH *.PEEK
  
  Revision  Changes    Path
  1.4       +1 -12     james-server/proposals/imap2/test/org/apache/james/imapserver/FetchSingleMessage.test
  
  Index: FetchSingleMessage.test
  ===================================================================
  RCS file: /home/cvs/james-server/proposals/imap2/test/org/apache/james/imapserver/FetchSingleMessage.test,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- FetchSingleMessage.test	30 Nov 2003 10:48:47 -0000	1.3
  +++ FetchSingleMessage.test	30 Dec 2003 00:24:32 -0000	1.4
  @@ -6,6 +6,7 @@
   
   # BODY[]
   # Not PEEK, so the Seen flag is implicitly set.
  +# TODO - should test that this flag is persisted
   C: f1 FETCH 1 (BODY[])
   S: \* 1 FETCH \(FLAGS \(\\Seen\) BODY\[\] \{255\}
   S: Date: Mon, 7 Feb 1994 21:52:25 -0800 \(PST\)
  @@ -67,18 +68,6 @@
   
   # todo - multipart messages.
   # todo - partial fetch BODY[]<0.100>
  -
  -# BODY.PEEK[]
  -# BODY.PEEK[HEADER]
  -# BODY.PEEK[HEADER.FIELDS]
  -# BODY.PEEK[HEADER.FIELDS.NOT]
  -# BODY.PEEK[MIME]
  -# BODY.PEEK[TEXT]
  -C: f1 FETCH 1 (BODY.PEEK[TEXT])
  -S: \* 1 FETCH \(BODY\[TEXT\] \{10\}
  -S: Test 01
  -S: \)
  -S: f1 OK FETCH completed
   
   # BODYSTRUCTURE - TODO should be returning extension data - language, md5 etc.
   C: f1 FETCH 1 (BODYSTRUCTURE)
  
  
  
  1.5       +1 -0      james-server/proposals/imap2/test/org/apache/james/imapserver/TestSelectedCommandsInSelectedState.java
  
  Index: TestSelectedCommandsInSelectedState.java
  ===================================================================
  RCS file: /home/cvs/james-server/proposals/imap2/test/org/apache/james/imapserver/TestSelectedCommandsInSelectedState.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- TestSelectedCommandsInSelectedState.java	13 Jul 2003 06:04:57 -0000	1.4
  +++ TestSelectedCommandsInSelectedState.java	30 Dec 2003 00:24:32 -0000	1.5
  @@ -99,6 +99,7 @@
           suite.addTest( new TestSelectedCommandsInSelectedState( "Search" ) );
           suite.addTest( new TestSelectedCommandsInSelectedState( "FetchSingleMessage" )
);
           suite.addTest( new TestSelectedCommandsInSelectedState( "FetchMultipleMessages"
) );
  +        suite.addTest( new TestSelectedCommandsInSelectedState( "FetchPeek" ) );
           suite.addTest( new TestSelectedCommandsInSelectedState( "Store" ) );
           suite.addTest( new TestSelectedCommandsInSelectedState( "Copy" ) );
           suite.addTest( new TestSelectedCommandsInSelectedState( "Uid" ) );
  
  
  
  1.1                  james-server/proposals/imap2/test/org/apache/james/imapserver/FetchPeek.test
  
  Index: FetchPeek.test
  ===================================================================
  # Tests for PEEK fetches, ensuring that the SEEN flag is not set.
  C: f1 STORE 2 +FLAGS.SILENT (\Flagged)
  S: f1 OK STORE completed
  
  # Check that the initial flags are correct
  C: f1 FETCH 2 (FLAGS)
  S: \* 2 FETCH \(FLAGS \(\\Flagged\)\)
  S: f1 OK FETCH completed
  
  # BODY.PEEK[]
  C: f1 FETCH 2 (BODY.PEEK[])
  S: \* 2 FETCH \(BODY\[\] \{255\}
  S: Date: Mon, 7 Feb 1994 21:52:25 -0800 \(PST\)
  S: From: Fred Foobar <foobar@Blurdybloop\.COM>
  S: Subject: Test 02
  S: To: mooch@owatagu\.siam\.edu
  S: Message-Id: <B27397-0100000@Blurdybloop\.COM>
  S: MIME-Version: 1\.0
  S: Content-Type: TEXT/PLAIN; CHARSET=US-ASCII
  S:
  S: Test 02
  S: \)
  S: f1 OK FETCH completed
  
  # BODY.PEEK[HEADER]
  C: f1 FETCH 2 (BODY.PEEK[HEADER])
  S: \* 2 FETCH \(BODY\[HEADER\] \{245\}
  S: Date: Mon, 7 Feb 1994 21:52:25 -0800 \(PST\)
  S: From: Fred Foobar <foobar@Blurdybloop\.COM>
  S: Subject: Test 02
  S: To: mooch@owatagu\.siam\.edu
  S: Message-Id: <B27397-0100000@Blurdybloop\.COM>
  S: MIME-Version: 1\.0
  S: Content-Type: TEXT/PLAIN; CHARSET=US-ASCII
  S:
  S: \)
  S: f1 OK FETCH completed
  
  # BODY.PEEK[HEADER.FIELDS]
  C: f1 FETCH 2 (BODY.PEEK[HEADER.FIELDS (From To)])
  S: \* 2 FETCH \(BODY\[HEADER\.FIELDS \(From To\)\] \{74\}
  S: From: Fred Foobar <foobar@Blurdybloop\.COM>
  S: To: mooch@owatagu\.siam\.edu
  S:
  S: \)
  S: f1 OK FETCH completed
  
  # BODY.PEEK[HEADER.FIELDS.NOT]
  C: f1 FETCH 2 (BODY.PEEK[HEADER.FIELDS.NOT (From To)])
  S: \* 2 FETCH \(BODY\[HEADER\.FIELDS\.NOT \(From To\)\] \{173\}
  S: Date: Mon, 7 Feb 1994 21:52:25 -0800 \(PST\)
  S: Subject: Test 02
  S: Message-Id: <B27397-0100000@Blurdybloop\.COM>
  S: MIME-Version: 1\.0
  S: Content-Type: TEXT/PLAIN; CHARSET=US-ASCII
  S:
  S: \)
  S: f1 OK FETCH completed
  
  # BODY.PEEK[MIME]
  # TODO - not yet implemented
  
  # BODY.PEEK[TEXT]
  C: f1 FETCH 2 (BODY.PEEK[TEXT])
  S: \* 2 FETCH \(BODY\[TEXT\] \{10\}
  S: Test 02
  S: \)
  S: f1 OK FETCH completed
  
  # Check that the flags are still correct
  C: f1 FETCH 2 (FLAGS)
  S: \* 2 FETCH \(FLAGS \(\\Flagged\)\)
  S: f1 OK FETCH completed
  
  
  
  

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


Mime
View raw message