Changeset 9599 in josm


Ignore:
Timestamp:
2016-01-23T23:26:39+01:00 (9 years ago)
Author:
Don-vip
Message:

see #11924 - add assertions to check if java.locale.providers enables CLDR as default because of JEP 252 in Java 9 (unit tests depending on default Java date formatting are failing)

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/I18n.java

    r9062 r9599  
    409409        // http://docs.oracle.com/javase/8/docs/technotes/guides/intl/enhancements.8.html#cldr
    410410        // FIXME: This can be removed after we switch to a minimal version of Java that enables CLDR by default
    411         // or includes all languages we need in the JRE. See http://openjdk.java.net/jeps/8043554 for Java 9
     411        // or includes all languages we need in the JRE. See http://openjdk.java.net/jeps/252 for Java 9
    412412        Utils.updateSystemProperty("java.locale.providers", "JRE,CLDR");
    413413
  • trunk/test/unit/org/openstreetmap/josm/tools/ExceptionUtilTest.java

    r9488 r9599  
    9595    @Test
    9696    public void testExplainChangesetClosedException() {
     97        // This test relies on the fact that CLDR is not the default local provider (see I18n.init)
     98        assertEquals("JRE,CLDR", System.getProperty("java.locale.providers"));
     99
    97100        assertEquals("<html>Failed to upload to changeset <strong>0</strong><br>because it has already been closed on ?.",
    98101                ExceptionUtil.explainChangesetClosedException(new ChangesetClosedException("")));
     
    116119    @Test
    117120    public void testExplainConflict() {
     121        // This test relies on the fact that CLDR is not the default local provider (see I18n.init)
     122        assertEquals("JRE,CLDR", System.getProperty("java.locale.providers"));
     123
    118124        int code = HttpURLConnection.HTTP_CONFLICT;
    119125        assertEquals("<html>The server reported that it has detected a conflict.</html>",
Note: See TracChangeset for help on using the changeset viewer.