Changeset 18992 in josm for trunk/test/unit


Ignore:
Timestamp:
2024-02-22T15:49:01+01:00 (9 months ago)
Author:
taylor.smock
Message:

See #23485/r18989: Fix broken tests

The tests just needed to have a category set.

Location:
trunk/test/unit/org/openstreetmap/josm/data/imagery
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/data/imagery/WMSEndpointTileSourceTest.java

    r18870 r18992  
    7575                "<id>OSM_Inspector-Geometry</id>\n" +
    7676                "<type>wms_endpoint</type>\n" +
     77                "<category>qa</category>\n" +
    7778                "<url><![CDATA[" + tileServer.url("/capabilities") + "]]></url>\n" +
    7879                "<icon>data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsSAAALEgHS3X78AAAB5UlEQVQ4y4WTwWsTURDG" +
     
    125126                "        <id>geovekst-nib-historic</id>\n" +
    126127                "        <type>wms_endpoint</type>\n" +
     128                "        <category>photo</category>\n" +
    127129                "        <country-code>NO</country-code>\n" +
    128130                "        <description lang=\"en\">Historic Norwegian orthophotos and maps, courtesy of Geovekst and Norkart.</description>\n" +
  • trunk/test/unit/org/openstreetmap/josm/data/imagery/WMTSTileSourceTest.java

    r18766 r18992  
    1818import java.nio.file.Paths;
    1919import java.util.ArrayList;
    20 import java.util.Arrays;
    2120import java.util.Collections;
    2221import java.util.List;
    2322import java.util.concurrent.TimeUnit;
    2423
    25 import com.github.tomakehurst.wiremock.WireMockServer;
    26 import com.github.tomakehurst.wiremock.client.WireMock;
    2724import org.apache.commons.io.FileUtils;
    2825import org.junit.jupiter.api.Disabled;
     
    4845import org.openstreetmap.josm.tools.ReflectionUtils;
    4946
     47import com.github.tomakehurst.wiremock.WireMockServer;
     48import com.github.tomakehurst.wiremock.client.WireMock;
     49
    5050/**
    5151 * Unit tests for class {@link WMTSTileSource}.
     
    276276        ProjectionRegistry.setProjection(Projections.getProjectionByCode("EPSG:3857"));
    277277        ImageryInfo ontario = getImagery(TestUtils.getTestDataRoot() + "wmts/WMTSCapabilities-Ontario.xml");
    278         ontario.setDefaultLayers(Arrays.asList(new DefaultLayer[] {
    279                 new DefaultLayer(ImageryType.WMTS, "Basemap_Imagery_2014", null, "default028mm")
    280         }));
     278        ontario.setDefaultLayers(Collections.singletonList(new DefaultLayer(ImageryType.WMTS, "Basemap_Imagery_2014", null, "default028mm")));
    281279        WMTSTileSource testSource = new WMTSTileSource(ontario);
    282280        testSource.initProjection(ProjectionRegistry.getProjection());
     
    293291        ProjectionRegistry.setProjection(Projections.getProjectionByCode("EPSG:3857"));
    294292        ImageryInfo ontario = getImagery(TestUtils.getTestDataRoot() + "wmts/WMTSCapabilities-Ontario.xml");
    295         ontario.setDefaultLayers(Arrays.asList(new DefaultLayer[] {
     293        ontario.setDefaultLayers(Collections.singletonList(
    296294                new DefaultLayer(ImageryType.WMTS, "Basemap_Imagery_2014", null, "GoogleMapsCompatible")
    297         }));
     295        ));
    298296        WMTSTileSource testSource = new WMTSTileSource(ontario);
    299297        testSource.initProjection(ProjectionRegistry.getProjection());
     
    393391                "<id>landsat</id>\n" +
    394392                "<type>wmts</type>\n" +
     393                "<category>photo</category>\n" +
    395394                "<url><![CDATA[" + tileServer.url("/getcapabilities.xml") + "]]></url>\n" +
    396395                "<default-layers>" +
Note: See TracChangeset for help on using the changeset viewer.