Changeset 15555 in josm for trunk/test/unit/org
- Timestamp:
- 2019-12-03T16:28:41+01:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/actions/CombineWayActionTest.java
r14604 r15555 3 3 4 4 import static org.junit.Assert.assertEquals; 5 import static org.junit.Assert.assertNull; 5 6 6 7 import java.io.IOException; … … 46 47 DataSet ds = OsmReader.parseDataSet(is, null); 47 48 NodeGraph graph = NodeGraph.createNearlyUndirectedGraphFromNodeWays(ds.getWays()); 48 List<Node> path = graph.buildSpanningPath ();49 List<Node> path = graph.buildSpanningPathNoRemove(); 49 50 assertEquals(10, path.size()); 50 51 Set<Long> firstAndLastObtained = new HashSet<>(); … … 55 56 firstAndLastExpected.add(35213705L); 56 57 assertEquals(firstAndLastExpected, firstAndLastObtained); 58 } 59 } 60 61 /** 62 * Non-regression test for bug #1835 (combine way with overlapping ways) 63 * @throws IOException if any I/O error occurs 64 * @throws IllegalDataException if OSM parsing fails 65 */ 66 @Test 67 public void testTicket18385() throws IOException, IllegalDataException { 68 try (InputStream is = TestUtils.getRegressionDataStream(18385, "data.osm")) { 69 DataSet ds = OsmReader.parseDataSet(is, null); 70 NodeGraph graph = NodeGraph.createNearlyUndirectedGraphFromNodeWays(ds.getWays()); 71 List<Node> path = graph.buildSpanningPathNoRemove(); 72 assertNull(path); 57 73 } 58 74 }
Note:
See TracChangeset
for help on using the changeset viewer.