def METHOD_NAME(self, app):
    resp = app.get("/wmts/1.0.0/WMTSCapabilities.xml")
    xml = resp.lxml
    assert validate_with_xsd(
        xml, xsd_name="wmts/1.0/wmtsGetCapabilities_response.xsd"
    )
    assert len(xml.xpath("//wmts:Layer", namespaces=ns_wmts)) == 5
    assert (
        len(xml.xpath("//wmts:Contents/wmts:TileMatrixSet", namespaces=ns_wmts))
        == 5
    )
    # check InfoFormat for queryable layers
    for layer in xml.xpath("//wmts:Layer", namespaces=ns_wmts):
        if layer.findtext("ows:Identifier", namespaces=ns_wmts) in (
            "wms_cache",
            "wms_cache_multi",
            "gk3_cache",
            "tms_cache",
        ):
            assert layer.xpath("wmts:InfoFormat/text()", namespaces=ns_wmts) == [
                "application/gml+xml; version=3.1",
                "application/json",
            ]
        else:
            assert layer.xpath("wmts:InfoFormat/text()", namespaces=ns_wmts) == []
    # check ResourceURL for wms_cache
    layer = xml.xpath(
        '//wmts:Layer[ows:Identifier/text()="wms_cache"]', namespaces=ns_wmts
    )[0]
    resourceURLs = layer.xpath("wmts:ResourceURL", namespaces=ns_wmts)
    for rurl, format, type, template in [
        [
            resourceURLs[0],
            "image/jpeg",
            "tile",
            "http://localhost/wmts/myrest/wms_cache/{TileMatrixSet}/{TileMatrix}/{TileCol}/{TileRow}.jpeg",
        ],
        [
            resourceURLs[1],
            "application/gml+xml; version=3.1",
            "FeatureInfo",
            "http://localhost/wmts/myrest/wms_cache/{TileMatrixSet}/{TileMatrix}/{TileCol}/{TileRow}/{I}/{J}.gml",
        ],
        [
            resourceURLs[2],
            "application/json",
            "FeatureInfo",
            "http://localhost/wmts/myrest/wms_cache/{TileMatrixSet}/{TileMatrix}/{TileCol}/{TileRow}/{I}/{J}.geojson",
        ],
    ]:
        assert rurl.attrib["format"] == format
        assert rurl.attrib["resourceType"] == type
        assert rurl.attrib["template"] == template