Bernd Fondermann wrote:
since your last commits, some unit tests are no longer succeeding on my
local trunk. two are easy fixes, but with the first one i am not so
sure...
Thank you Bernd for your test/help!
### MimeMessage*Test
"expected:<...Cp1252...> but was:<...ISO-8859-1...>"
impl seems to be platform specific and does fail on my unix env.
is there a generic solution to this?
Understood.
I added a weird default locale to my junit test run and I'm able to
reproduce the issue.
I'll try to make the test code locale independent.
this failure occurs in all of these:
MimeMessageCopyOnWriteProxyTest
MimeMessageFromSharedStreamTest
MimeMessageFromStreamTest
MimeMessageTest
MimeMessageFromMimeMessageTest
MimeMessageWrapperTest
### org.apache.james.core.MailImplTest
getSize() behavior has been changed in MailImpl, so we have to adjust here:
Yes, I saw this but I didn't fix it because I was not sure the new
behaviour was better than the previous.
I think we can safely change it to 0.
- helperTestMessageSize(mail, mimeMessage.getSize()); //
MockMimeMessage default is -1 (accord. to javax.mail javadoc)
+ helperTestMessageSize(mail, 0);
### org.apache.james.remotemanager.RemoteManagerTest
I propose the following change to become platform independent:
IIRC this is a known bug of James. new lines in the telnet based tcp/ip
protocols like SMTP and POP3 should always be CRLF (system indipendent).
So the correct test is \r\n while we have a bug under linux where our
protocols uses only \n
We evaluated the use of MINA to resolve this issue too, but MINA SSL
suport requires java 5...
I'm not sure wether we should keep the failing test to remember the
issue or we should fix the test for the known bug: what do you think?
+ public static final String LINE_SEPARATOR =
System.getProperties().getProperty("line.separator");
[..]
-
allAnswerLines.addAll(Arrays.asList(stringBuffer.toString().split("\r\n")));
+
allAnswerLines.addAll(Arrays.asList(stringBuffer.toString().split(LINE_SEPARATOR)));
Stefano
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]