You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Stephen Colebourne (JIRA)" <ji...@apache.org> on 2017/10/27 12:03:00 UTC

[jira] [Created] (LANG-1362) Fix tests for Java 9

Stephen Colebourne created LANG-1362:
----------------------------------------

             Summary: Fix tests for Java 9
                 Key: LANG-1362
                 URL: https://issues.apache.org/jira/browse/LANG-1362
             Project: Commons Lang
          Issue Type: Bug
            Reporter: Stephen Colebourne
             Fix For: 3.7


On Java 9 I see DateUtilsTest fail. This is because "MST7MDT" zone is not formatted as "MST". I'm unclear as to why this is, but it is not relevant to what the test is trying to do. As such, I've changed the zone to "America/Denver" and changed the format letter from "z" to "XXX" to make it more reliable.

The PR also uses try-finally when setting the default time-zone to avoid pollution of global state if a test fails (the pollution here made it look like 8 test failures when there was only in fact 1).



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)