Changeset 2471 in josm for trunk/test/unit/org
- Timestamp:
- 2009-11-18T18:50:38+01:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/data/osm/DataSetMergerTest.java
r2443 r2471 17 17 import java.util.logging.Logger; 18 18 19 import org.junit.Before; 19 20 import org.junit.BeforeClass; 20 21 import org.junit.Test; … … 62 63 } 63 64 65 @Before 66 public void setUp() { 67 User.clearUserMap(); 68 } 69 64 70 /** 65 71 * two identical nodes, even in id and version. No confict expected. … … 348 354 /** 349 355 * their node is not visible and doesn't exist in my data set 350 * => ignore their node 356 * => we can't ignore it because we'd run into troubles in case of multi fetch 357 * which can return invisible objects 351 358 * 352 359 */ … … 373 380 Node n2 = (Node)my.getPrimitiveById(1,OsmPrimitiveType.NODE); 374 381 assertEquals(0,visitor.getConflicts().size()); 375 assertEquals( 1, my.getNodes().size());382 assertEquals(2, my.getNodes().size()); 376 383 assertEquals(n,n2); 377 384 } … … 775 782 theirWay.addNode(n3); 776 783 theirWay.addNode(n4); 777 theirWay.setUser(User.createOsmUser(1111, "their")); 784 User user = User.createOsmUser(1111, "their"); 785 theirWay.setUser(user); 778 786 theirWay.setTimestamp(new Date()); 779 787 their.addPrimitive(theirWay); … … 895 903 theirWay.addNode(n4); 896 904 theirWay.addNode(n5); 897 theirWay.setUser(User.createOsmUser(1111, "their")); 905 User user = User.getById(1111); 906 if (user == null) { 907 User.createOsmUser(1111, "their"); 908 } 909 theirWay.setUser(user); 898 910 theirWay.setTimestamp(new Date()); 899 911 their.addPrimitive(theirWay); … … 1081 1093 assertTrue(!w.getNode(1).incomplete); 1082 1094 } 1095 1083 1096 }
Note:
See TracChangeset
for help on using the changeset viewer.