Changeset 16574 in josm for trunk/test
- Timestamp:
- 2020-06-08T21:02:37+02:00 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/command/SequenceCommandTest.java
r13079 r16574 5 5 import static org.junit.Assert.assertEquals; 6 6 import static org.junit.Assert.assertFalse; 7 import static org.junit.Assert.assertNotSame; 7 8 import static org.junit.Assert.assertNull; 9 import static org.junit.Assert.assertSame; 8 10 import static org.junit.Assert.assertTrue; 9 11 import static org.junit.Assert.fail; … … 298 300 } 299 301 } 302 303 /** 304 * Test {@link SequenceCommand#wrapIfNeeded} 305 */ 306 @Test 307 public void testWrapIfNeeded() { 308 DataSet ds = new DataSet(); 309 TestCommand command1 = new TestCommand(ds, Collections.<OsmPrimitive>singletonList(testData.existingNode)); 310 TestCommand command2 = new TestCommand(ds, Collections.<OsmPrimitive>singletonList(testData.existingNode2)); 311 assertSame(command1, SequenceCommand.wrapIfNeeded("foo", command1)); 312 assertNotSame(command1, SequenceCommand.wrapIfNeeded("foo", command1, command2)); 313 assertEquals(new SequenceCommand("foo", command1, command2), SequenceCommand.wrapIfNeeded("foo", command1, command2)); 314 } 300 315 }
Note:
See TracChangeset
for help on using the changeset viewer.