Changeset 17343 in josm for trunk/test/unit/org
- Timestamp:
- 2020-11-23T21:39:48+01:00 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/actions/CreateMultipolygonActionTest.java
r17275 r17343 4 4 import static org.junit.jupiter.api.Assertions.assertEquals; 5 5 import static org.junit.jupiter.api.Assertions.assertFalse; 6 import static org.junit.jupiter.api.Assertions.assertNotNull; 6 7 import static org.junit.jupiter.api.Assertions.assertTrue; 7 8 … … 12 13 import java.util.TreeMap; 13 14 15 import org.junit.jupiter.api.Test; 14 16 import org.junit.jupiter.api.extension.RegisterExtension; 15 import org.junit.jupiter.api.Test;16 17 import org.openstreetmap.josm.TestUtils; 17 18 import org.openstreetmap.josm.command.SequenceCommand; … … 156 157 157 158 } 159 160 /** 161 * Non-regression test for <a href="https://josm.openstreetmap.de/ticket/20110">Bug #20110</a>. 162 * @throws Exception if an error occurs 163 */ 164 @Test 165 void testTicket20110() throws Exception { 166 DataSet ds = OsmReader.parseDataSet(TestUtils.getRegressionDataStream(20110, "data.osm"), null); 167 assertEquals(1, ds.getRelations().size()); 168 Relation mp = ds.getRelations().iterator().next(); 169 assertEquals("wetland", mp.get("natural")); 170 long numCoastlineWays = ds.getWays().stream().filter(w -> "coastline".equals(w.get("natural"))).count(); 171 Relation modMp = createMultipolygon(ds.getWays(), "type:way", mp, false); 172 assertNotNull(modMp); 173 assertEquals("wetland", modMp.get("natural")); 174 assertEquals(numCoastlineWays, ds.getWays().stream().filter(w -> "coastline".equals(w.get("natural"))).count()); 175 } 158 176 }
Note:
See TracChangeset
for help on using the changeset viewer.