Hi,

after fixing some JDK9 related bugs in our build for Groovy we stumbled over

new SimpleDateFormat("EEE MMM dd HH:mm:ss zzz yyyy", Locale.US).parse("Thu Jan 01 01:00:00 CET 1970")

failing to parse with

java.text.ParseException: Unparseable date: "Thu Jan 01 01:00:00 CET 1970"
    at java.text.DateFormat.parse(DateFormat.java:366)

This happens not with my local machine using jdk1.9.0-ea-b68, but it does fail on our CI server used revision 0906b79c9df4 for this.

A second case is this one:

        Locale locale = Locale.UK
        Locale.setDefault locale
        TimeZone.setDefault TimeZone.getTimeZone('Etc/GMT')
        Date d = new Date(0)
        assertEquals '01/01/70', 
DateFormat.getDateInstance(DateFormat.SHORT).format(d);

the assert used to work, but now the format changed to print 01/01/1970 instead of 01/01/70. With the same constellation regarding jdk versions.

Are those expected to fail? Can someone verify this?

bye Jochen Theodorou

--
Jochen "blackdrag" Theodorou
blog: http://blackdragsview.blogspot.com/

Reply via email to