Changeset 17275 in josm for trunk/test/unit/org/openstreetmap/josm/gui/autofilter
- Timestamp:
- 2020-10-28T20:41:00+01:00 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/gui/autofilter/AutoFilterRuleTest.java
r15843 r17275 2 2 package org.openstreetmap.josm.gui.autofilter; 3 3 4 import static org.junit. Assert.assertArrayEquals;5 import static org.junit. Assert.assertEquals;4 import static org.junit.jupiter.api.Assertions.assertArrayEquals; 5 import static org.junit.jupiter.api.Assertions.assertEquals; 6 6 7 7 import java.util.NoSuchElementException; … … 9 9 import java.util.stream.IntStream; 10 10 11 import org.junit. Rule;12 import org.junit. Test;11 import org.junit.jupiter.api.extension.RegisterExtension; 12 import org.junit.jupiter.api.Test; 13 13 import org.openstreetmap.josm.data.osm.OsmPrimitive; 14 14 import org.openstreetmap.josm.data.osm.OsmUtils; … … 20 20 * Unit tests of {@link AutoFilterRule} class. 21 21 */ 22 publicclass AutoFilterRuleTest {22 class AutoFilterRuleTest { 23 23 24 24 /** 25 25 * Setup tests 26 26 */ 27 @R ule27 @RegisterExtension 28 28 @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD") 29 29 public JOSMTestRules test = new JOSMTestRules().i18n(); … … 33 33 */ 34 34 @Test 35 publicvoid testTagValuesForPrimitive() {35 void testTagValuesForPrimitive() { 36 36 // #17109, support values like 0.5 or 1.5 - level values are multiplied by 2 when parsing, values are divided by 2 for formatting 37 37 final AutoFilterRule level = AutoFilterRule.getDefaultRule("level").orElseThrow(NoSuchElementException::new); … … 52 52 */ 53 53 @Test 54 publicvoid testTagValuesForPrimitiveInclineUnit() {54 void testTagValuesForPrimitiveInclineUnit() { 55 55 final AutoFilterRule incline = AutoFilterRule.getDefaultRule("incline").orElseThrow(NoSuchElementException::new); 56 56 assertTagValuesForPrimitive(incline, "way incline=up"); … … 63 63 */ 64 64 @Test 65 publicvoid testTagValuesForPrimitivesDefaults() {65 void testTagValuesForPrimitivesDefaults() { 66 66 final AutoFilterRule layer = AutoFilterRule.getDefaultRule("layer").orElseThrow(NoSuchElementException::new); 67 67 assertTagValuesForPrimitive(layer, "way foo=bar"); … … 85 85 */ 86 86 @Test 87 publicvoid testValueFormatter() {87 void testValueFormatter() { 88 88 final AutoFilterRule voltage = AutoFilterRule.getDefaultRule("voltage").orElseThrow(NoSuchElementException::new); 89 89 assertEquals("230V", voltage.formatValue(230));
Note:
See TracChangeset
for help on using the changeset viewer.