Changeset 12718 in josm for trunk/test
- Timestamp:
- 2017-09-04T00:50:22+02:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/command/CommandTest.java
r12636 r12718 2 2 package org.openstreetmap.josm.command; 3 3 4 import static org.junit.Assert.assertFalse;5 4 import static org.junit.Assert.assertSame; 6 import static org.junit.Assert.assertTrue;7 5 8 6 import java.util.Arrays; … … 50 48 51 49 /** 52 * Test {@link Command#invalidBecauselayerRemoved(org.openstreetmap.josm.gui.layer.Layer)} 50 * Test {@link Command#getLayer()} 51 * @deprecated to be removed end of 2017 53 52 */ 54 53 @Test 55 public void testInvalidBecauselayerRemoved() { 56 OsmDataLayer layer2 = new OsmDataLayer(new DataSet(), "test", null); 57 58 Command command = new NopCommand(); 59 assertFalse(command.invalidBecauselayerRemoved(layer2)); 60 assertTrue(command.invalidBecauselayerRemoved(testData.layer)); 61 62 Command command2 = new NopCommand(layer2); 63 assertTrue(command2.invalidBecauselayerRemoved(layer2)); 64 assertFalse(command2.invalidBecauselayerRemoved(testData.layer)); 65 } 66 67 /** 68 * Test {@link Command#getLayer()} 69 */ 70 @Test 54 @Deprecated 71 55 public void testGetLayer() { 72 56 OsmDataLayer layer2 = new OsmDataLayer(new DataSet(), "test", null); 73 57 Command command = new NopCommand(); 74 Command command2 = new NopCommand(layer2 );58 Command command2 = new NopCommand(layer2.data); 75 59 assertSame(testData.layer, command.getLayer()); 76 60 assertSame(layer2, command2.getLayer()); … … 98 82 } 99 83 100 NopCommand( OsmDataLayer layer) {101 super( layer);84 NopCommand(DataSet dataset) { 85 super(dataset); 102 86 } 103 87
Note:
See TracChangeset
for help on using the changeset viewer.