[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gzz-commits] gzz/test/gzz/modules/email converter.test
From: |
Marc Schiereck |
Subject: |
[Gzz-commits] gzz/test/gzz/modules/email converter.test |
Date: |
Fri, 25 Oct 2002 17:29:59 -0400 |
CVSROOT: /cvsroot/gzz
Module name: gzz
Changes by: Marc Schiereck <address@hidden> 02/10/25 17:29:59
Modified files:
test/gzz/modules/email: converter.test
Log message:
E-mails now are saved with CRLF-linebreaks.
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/test/gzz/modules/email/converter.test.diff?tr1=1.1&tr2=1.2&r1=text&r2=text
Patches:
Index: gzz/test/gzz/modules/email/converter.test
diff -u gzz/test/gzz/modules/email/converter.test:1.1
gzz/test/gzz/modules/email/converter.test:1.2
--- gzz/test/gzz/modules/email/converter.test:1.1 Wed Oct 16 19:34:53 2002
+++ gzz/test/gzz/modules/email/converter.test Fri Oct 25 17:29:59 2002
@@ -17,6 +17,7 @@
import StringIO
import string
+import re
import gzz
import java
@@ -163,8 +164,13 @@
gzz.mediaserver.storage.TransientStorer())
gzz.modules.email.converter.storeMailbox(mboxfile, medServ)
- mailIDs = medServ.getIDs()
+ p = re.compile( '(\r\n|\n)')
+ mail1c = p.sub('\r\n', mail1)
+ mail2c = p.sub('\r\n', mail2)
+ mail3c = p.sub('\r\n', mail3)
+
+ mailIDs = medServ.getIDs()
if mailIDs.size() != 3:
raise java.lang.Error()
@@ -172,10 +178,9 @@
for mail in mailIDs.iterator():
tmail = java.lang.String(medServ.getDatum(mail).getBytes())
- if tmail.equals(mail1): m1 = 1
- if tmail.equals(mail2): m2 = 1
- if tmail.equals(mail3): m3 = 1
+ if tmail.equals(mail1c): m1 = 1
+ if tmail.equals(mail2c): m2 = 1
+ if tmail.equals(mail3c): m3 = 1
if not (m1 and m2 and m3):
raise java.lang.Error()
-