Changeset 17967 in josm for trunk/test
- Timestamp:
- 2021-07-09T01:09:04+02:00 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/tools/JosmDecimalFormatSymbolsProviderTest.java
r17677 r17967 6 6 import static org.junit.jupiter.api.Assumptions.assumeTrue; 7 7 8 import java.io.IOException; 9 import java.io.InputStream; 10 import java.nio.charset.StandardCharsets; 8 11 import java.text.DecimalFormat; 9 12 import java.util.Locale; 10 13 import java.util.stream.Stream; 11 14 15 import org.junit.jupiter.api.BeforeAll; 12 16 import org.junit.jupiter.api.Test; 13 17 import org.junit.jupiter.api.extension.RegisterExtension; … … 27 31 @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD") 28 32 public JOSMTestRules test = new JOSMTestRules(); 33 34 @BeforeAll 35 static void beforeAll() throws IOException { 36 if (Utils.getJavaVersion() >= 9) { 37 assertEquals("SPI,JRE,CLDR", System.getProperty("java.locale.providers"), "This test must be launched with -Djava.locale.providers=SPI,JRE,CLDR"); 38 try (InputStream in = I18n.class.getResourceAsStream("/META-INF/services/java.text.spi.DecimalFormatSymbolsProvider")) { 39 assertEquals("org.openstreetmap.josm.tools.JosmDecimalFormatSymbolsProvider", new String(Utils.readBytesFromStream(in), StandardCharsets.UTF_8).trim()); 40 } 41 } 42 } 29 43 30 44 @Test
Note:
See TracChangeset
for help on using the changeset viewer.