Index: trunk/test/unit/org/openstreetmap/josm/gui/preferences/imagery/ImageryPreferenceTestIT.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/gui/preferences/imagery/ImageryPreferenceTestIT.java	(revision 14498)
+++ trunk/test/unit/org/openstreetmap/josm/gui/preferences/imagery/ImageryPreferenceTestIT.java	(revision 14499)
@@ -16,6 +16,15 @@
 import org.junit.Rule;
 import org.junit.Test;
+import org.openstreetmap.gui.jmapviewer.tilesources.AbstractTileSource;
+import org.openstreetmap.gui.jmapviewer.tilesources.BingAerialTileSource;
+import org.openstreetmap.gui.jmapviewer.tilesources.ScanexTileSource;
+import org.openstreetmap.gui.jmapviewer.tilesources.TemplatedTMSTileSource;
 import org.openstreetmap.josm.data.imagery.ImageryInfo;
 import org.openstreetmap.josm.data.imagery.ImageryLayerInfo;
+import org.openstreetmap.josm.data.imagery.TemplatedWMSTileSource;
+import org.openstreetmap.josm.data.imagery.WMSEndpointTileSource;
+import org.openstreetmap.josm.data.imagery.WMTSTileSource;
+import org.openstreetmap.josm.data.imagery.WMTSTileSource.WMTSGetCapabilitiesException;
+import org.openstreetmap.josm.data.projection.ProjectionRegistry;
 import org.openstreetmap.josm.testutils.JOSMTestRules;
 import org.openstreetmap.josm.tools.HttpClient;
@@ -35,5 +44,5 @@
     @Rule
     @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD")
-    public JOSMTestRules test = new JOSMTestRules().https().timeout(10000*60);
+    public JOSMTestRules test = new JOSMTestRules().https().projection().projectionNadGrids().timeout(10000*60);
 
     private final Map<String, Map<ImageryInfo, List<String>>> errors = Collections.synchronizedMap(new TreeMap<>());
@@ -80,6 +89,31 @@
         checkUrl(info, info.getTermsOfUseURL());
 
+        try {
+            getTileSource(info);
+        } catch (IOException | WMTSGetCapabilitiesException | IllegalArgumentException e) {
+            addError(info, e.toString());
+        }
+
         for (ImageryInfo mirror : info.getMirrors()) {
             checkEntry(mirror);
+        }
+    }
+
+    private static AbstractTileSource getTileSource(ImageryInfo info) throws IOException, WMTSGetCapabilitiesException {
+        switch (info.getImageryType()) {
+            case BING:
+                return new BingAerialTileSource();
+            case SCANEX:
+                return new ScanexTileSource(info);
+            case TMS:
+                return new TemplatedTMSTileSource(info);
+            case WMS:
+                return new TemplatedWMSTileSource(info, ProjectionRegistry.getProjection());
+            case WMS_ENDPOINT:
+                return new WMSEndpointTileSource(info, ProjectionRegistry.getProjection());
+            case WMTS:
+                return new WMTSTileSource(info);
+            default:
+                throw new UnsupportedOperationException(info.toString());
         }
     }
