Changeset 18614 in josm for trunk/test/unit
- Timestamp:
- 2022-12-13T14:25:40+01:00 (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/gui/layer/geoimage/GeoImageLayerTest.java
r18037 r18614 4 4 import static org.junit.jupiter.api.Assertions.assertThrows; 5 5 6 import java.util.Collections; 7 8 import org.junit.jupiter.api.extension.RegisterExtension; 6 9 import org.openstreetmap.josm.data.osm.DataSet; 7 10 import org.openstreetmap.josm.gui.layer.OsmDataLayer; 11 import org.openstreetmap.josm.testutils.JOSMTestRules; 8 12 import org.openstreetmap.josm.testutils.annotations.BasicPreferences; 9 13 … … 16 20 @BasicPreferences 17 21 class GeoImageLayerTest { 22 @RegisterExtension 23 static JOSMTestRules josmTestRules = new JOSMTestRules().main(); 18 24 19 25 /** … … 22 28 @Test 23 29 void testMergeFromIAE() { 24 assertThrows(IllegalArgumentException.class, () -> new GeoImageLayer(null, null).mergeFrom(new OsmDataLayer(new DataSet(), "", null))); 30 GeoImageLayer geoImageLayer = new GeoImageLayer(Collections.emptyList(), null); 31 OsmDataLayer osmDataLayer = new OsmDataLayer(new DataSet(), "", null); 32 assertThrows(IllegalArgumentException.class, () -> geoImageLayer.mergeFrom(osmDataLayer)); 25 33 } 26 34 }
Note:
See TracChangeset
for help on using the changeset viewer.