Phil Steitz wrote:

> On 9/6/06, Jörg Schaible <[EMAIL PROTECTED]> wrote:
>> Jörg Schaible wrote on Tuesday, September 05, 2006 6:35 PM:
>>
>> > Hi Phil,
>> >
>> > [EMAIL PROTECTED] wrote:
>> >
>> >> Failed build logs:
>> >> http://people.apache.org/~psteitz/commons-nightlies/20060905/id.log
>> >
>> > sorry, I have no idea how to "fix" this test on a time shifting
>> > machine ... :-(
>>
>> OK, I'll tried to make the test even more robust, but that the test may
>> still fail occationally on time-shifting machines.
>>
> 
> I see [beanutils] failed last night on a time-related test as well.

It makes also false assumptions about the Locale:

==== %< ====
Converting pattern 'd MMMM yyyy' for de_AT
java.lang.IllegalArgumentException: Illegal pattern character 'd'
        at
org.apache.commons.beanutils.locale.converters.DateLocaleConverter.convertPattern(DateLocaleConverter.java:332)
        at
org.apache.commons.beanutils.locale.converters.DateLocaleConverter.convertLocalizedPattern(DateLocaleConverter.java:302)
        at
org.apache.commons.beanutils.locale.converters.DateLocaleConverter.parse(DateLocaleConverter.java:262)
        at
org.apache.commons.beanutils.locale.BaseLocaleConverter.convert(BaseLocaleConverter.java:226)
        at
org.apache.commons.beanutils.locale.BaseLocaleConverter.convert(BaseLocaleConverter.java:182)
        at
org.apache.commons.beanutils.locale.converters.BaseLocaleConverterTestCase.convertValueWithPattern(BaseLocaleConverterTestCase.java:151)
        at
org.apache.commons.beanutils.locale.converters.DateLocaleConverterTestCase.testConstructorMain(DateLocaleConverterTestCase.java:239)
==== %< ====

and the failing test for SqlDateConverterTestCase is because of a wrong
implementation of the test. Look at DateConverterTestBase.testConvertDate.
It fails to initialize the Calendar object with the right time. Despite the
other objects, this one must be initialized separate, simply add the line:

((Calendar)date[1]).setTimeInMillis(now);

and the test is independent of any time slice.

- Jörg


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to