Index: trunk/test/unit/org/openstreetmap/josm/TestUtils.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/TestUtils.java	(revision 8784)
+++ trunk/test/unit/org/openstreetmap/josm/TestUtils.java	(revision 8793)
@@ -107,3 +107,14 @@
         .toString();
     }
+
+    /**
+     * Returns the Java version as a double value.
+     * @return the Java version as a double value (1.7, 1.8, 1.9, etc.)
+     */
+    public static double getJavaVersion() {
+        String version = System.getProperty("java.version");
+        int pos = version.indexOf('.');
+        pos = version.indexOf('.', pos + 1);
+        return Double.parseDouble(version.substring(0, pos));
+    }
 }
Index: trunk/test/unit/org/openstreetmap/josm/data/projection/ProjectionRegressionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/data/projection/ProjectionRegressionTest.java	(revision 8784)
+++ trunk/test/unit/org/openstreetmap/josm/data/projection/ProjectionRegressionTest.java	(revision 8793)
@@ -15,13 +15,14 @@
 import java.util.HashMap;
 import java.util.HashSet;
-import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Map;
 import java.util.Random;
 import java.util.Set;
+import java.util.TreeSet;
 
 import org.junit.BeforeClass;
 import org.junit.Test;
 import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.TestUtils;
 import org.openstreetmap.josm.data.Bounds;
 import org.openstreetmap.josm.data.coor.EastNorth;
@@ -45,4 +46,5 @@
 
     private static final String PROJECTION_DATA_FILE = "data_nodist/projection-regression-test-data.csv";
+    private static final String PROJECTION_DATA_FILE_JAVA_9 = "data_nodist/projection-regression-test-data-java9.csv";
 
     private static class TestData {
@@ -53,5 +55,9 @@
     }
 
-    public static void main(String[] args) throws IOException, FileNotFoundException {
+    private static String getProjectionDataFile() {
+        return TestUtils.getJavaVersion() >= 1.9 ? PROJECTION_DATA_FILE_JAVA_9 : PROJECTION_DATA_FILE;
+    }
+
+    public static void main(String[] args) throws IOException {
         setUp();
 
@@ -62,5 +68,5 @@
 
         List<TestData> prevData = new ArrayList<>();
-        if (new File(PROJECTION_DATA_FILE).exists()) {
+        if (new File(getProjectionDataFile()).exists()) {
             prevData = readData();
         }
@@ -70,5 +76,5 @@
         }
 
-        Set<String> codesToWrite = new LinkedHashSet<>();
+        Set<String> codesToWrite = new TreeSet<>();
         for (TestData data : prevData) {
             if (supportedCodesMap.containsKey(data.code)) {
@@ -84,5 +90,5 @@
         Random rand = new Random();
         try (BufferedWriter out = new BufferedWriter(new OutputStreamWriter(
-                new FileOutputStream(PROJECTION_DATA_FILE), StandardCharsets.UTF_8))) {
+                new FileOutputStream(getProjectionDataFile()), StandardCharsets.UTF_8))) {
             out.write("# Data for test/unit/org/openstreetmap/josm/data/projection/ProjectionRegressionTest.java\n");
             out.write("# Format: 1. Projection code; 2. lat/lon; 3. lat/lon projected -> east/north; 4. east/north (3.) inverse projected\n");
@@ -108,5 +114,6 @@
 
     private static List<TestData> readData() throws IOException, FileNotFoundException {
-        try (BufferedReader in = new BufferedReader(new InputStreamReader(new FileInputStream(PROJECTION_DATA_FILE), StandardCharsets.UTF_8))) {
+        try (BufferedReader in = new BufferedReader(new InputStreamReader(new FileInputStream(getProjectionDataFile()),
+                StandardCharsets.UTF_8))) {
             List<TestData> result = new ArrayList<>();
             String line;
