Changeset 15216 in josm for trunk/test
- Timestamp:
- 2019-07-06T23:39:16+02:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/actions/downloadtasks/DownloadTaskListTest.java
r10945 r15216 2 2 package org.openstreetmap.josm.actions.downloadtasks; 3 3 4 import static org.junit.Assert.assertNull; 4 5 import static org.junit.Assert.assertTrue; 6 7 import java.awt.geom.Area; 8 import java.util.Collections; 5 9 6 10 import org.junit.Rule; 7 11 import org.junit.Test; 12 import org.openstreetmap.josm.data.Bounds; 13 import org.openstreetmap.josm.gui.progress.NullProgressMonitor; 8 14 import org.openstreetmap.josm.testutils.JOSMTestRules; 9 15 … … 29 35 assertTrue(new DownloadTaskList().getDownloadedPrimitives().isEmpty()); 30 36 } 37 38 /** 39 * Unit test of {@code DownloadTaskList#download} - empty cases. 40 * @throws Exception in case of error 41 */ 42 @Test 43 public void testDownloadAreaEmpty() throws Exception { 44 DownloadTaskList list = new DownloadTaskList(); 45 assertNull(list.download(false, 46 Collections.<Area>emptyList(), true, true, NullProgressMonitor.INSTANCE).get()); 47 assertTrue(list.getDownloadedPrimitives().isEmpty()); 48 assertNull(list.download(false, 49 Collections.<Area>emptyList(), false, false, NullProgressMonitor.INSTANCE).get()); 50 assertTrue(list.getDownloadedPrimitives().isEmpty()); 51 assertNull(list.download(false, 52 Collections.<Area>singletonList(new Area(new Bounds(0, 0, true).asRect())), false, false, NullProgressMonitor.INSTANCE).get()); 53 assertTrue(list.getDownloadedPrimitives().isEmpty()); 54 } 31 55 }
Note:
See TracChangeset
for help on using the changeset viewer.