Changeset 15671 in josm for trunk/test/unit/org/openstreetmap
- Timestamp:
- 2020-01-10T00:07:20+01:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/data/osm/OsmUtilsTest.java
r10945 r15671 4 4 import static org.junit.Assert.assertEquals; 5 5 import static org.junit.Assert.assertTrue; 6 7 import java.util.Arrays; 8 import java.util.stream.Collectors; 6 9 7 10 import org.junit.Rule; … … 40 43 OsmUtils.createPrimitive("noway name=Foo"); 41 44 } 45 46 @Test 47 public void testSplitMultipleValues() { 48 // examples from https://wiki.openstreetmap.org/wiki/Semi-colon_value_separator 49 assertEquals(Arrays.asList("B500", "B550"), OsmUtils.splitMultipleValues("B500;B550").collect(Collectors.toList())); 50 assertEquals(Arrays.asList("B500", "B550"), OsmUtils.splitMultipleValues("B500 ; B550").collect(Collectors.toList())); 51 assertEquals(Arrays.asList("Tu-Fr 08:00-18:00", "Mo 09:00-18:00", "Sa 09:00-12:00", "closed Aug"), 52 OsmUtils.splitMultipleValues("Tu-Fr 08:00-18:00;Mo 09:00-18:00;Sa 09:00-12:00;closed Aug").collect(Collectors.toList())); 53 } 42 54 }
Note:
See TracChangeset
for help on using the changeset viewer.