From 5ed600d1cd900412c9bf208f2de27955f96e2eb6 Mon Sep 17 00:00:00 2001 From: Olivia Guyot Date: Tue, 7 May 2024 00:09:16 +0200 Subject: [PATCH] e2e(datahub): mock ogc-api responses, remove wait --- .../src/e2e/datasetDetailPage.cy.ts | 37 ++- apps/datahub-e2e/src/fixtures/covoit-mel.json | 44 ++++ .../src/fixtures/covoit-mel_items.json | 248 ++++++++++++++++++ ...dins-familiaux-et-partages-de-roubaix.json | 44 ++++ ...amiliaux-et-partages-de-roubaix_items.json | 136 ++++++++++ apps/datahub-e2e/src/fixtures/ogcapi.json | 36 +++ .../src/fixtures/ogcapi_collections.json | 129 +++++++++ .../src/fixtures/ogcapi_conformance.json | 18 ++ 8 files changed, 690 insertions(+), 2 deletions(-) create mode 100644 apps/datahub-e2e/src/fixtures/covoit-mel.json create mode 100644 apps/datahub-e2e/src/fixtures/covoit-mel_items.json create mode 100644 apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix.json create mode 100644 apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix_items.json create mode 100644 apps/datahub-e2e/src/fixtures/ogcapi.json create mode 100644 apps/datahub-e2e/src/fixtures/ogcapi_collections.json create mode 100644 apps/datahub-e2e/src/fixtures/ogcapi_conformance.json diff --git a/apps/datahub-e2e/src/e2e/datasetDetailPage.cy.ts b/apps/datahub-e2e/src/e2e/datasetDetailPage.cy.ts index fab1ab8650..9bce4b8f32 100644 --- a/apps/datahub-e2e/src/e2e/datasetDetailPage.cy.ts +++ b/apps/datahub-e2e/src/e2e/datasetDetailPage.cy.ts @@ -3,6 +3,7 @@ import path from 'path' describe('dataset pages', () => { beforeEach(() => { + // GEOSERVER stubs cy.intercept( 'GET', '/geoserver/insee/ows?SERVICE=WMS&REQUEST=GetCapabilities', @@ -38,6 +39,8 @@ describe('dataset pages', () => { fixture: 'insee-rectangles_200m_menage_erbm.csv', } ) + + // OPENDATASOFT stub cy.intercept( 'GET', '/explore/dataset/population-millesimee-communes-francaises/download?format=csv&timezone=Europe/Berlin&use_labels_for_header=false', @@ -46,6 +49,38 @@ describe('dataset pages', () => { } ) + // OGC API stubs + cy.intercept( + 'GET', + '/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=json', + { + fixture: + 'liste-des-jardins-familiaux-et-partages-de-roubaix_items.json', + } + ) + cy.intercept('GET', '/data/ogcapi/collections/covoit-mel/items?f=jsonn', { + fixture: 'covoit-mel_items.json', + }) + cy.intercept( + 'GET', + '/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix?f=json', + { + fixture: 'liste-des-jardins-familiaux-et-partages-de-roubaix.json', + } + ) + cy.intercept('GET', '/data/ogcapi/collections/covoit-mel?f=json', { + fixture: 'covoit-mel.json', + }) + cy.intercept('GET', '/data/ogcapi/collections?f=json', { + fixture: 'ogcapi_collections.json', + }) + cy.intercept('GET', '/data/ogcapi/conformance?f=json', { + fixture: 'ogcapi_conformance.json', + }) + cy.intercept('GET', '/data/ogcapi/?f=json', { + fixture: 'ogcapi.json', + }) + // dataset without API, preview or downloads // cy.visit('/dataset/011963da-afc0-494c-a2cc-5cbd59e122e4') // dataset with map error @@ -641,8 +676,6 @@ describe('api form', () => { cy.get('@secondInput').clear() cy.get('@secondInput').type('87') - // eslint-disable-next-line cypress/no-unnecessary-waiting - cy.wait(3000) cy.get('@apiForm').find('gn-ui-dropdown-selector').as('dropdown') cy.get('@dropdown').eq(0).selectDropdownOption('geojson') diff --git a/apps/datahub-e2e/src/fixtures/covoit-mel.json b/apps/datahub-e2e/src/fixtures/covoit-mel.json new file mode 100644 index 0000000000..20d8b8e082 --- /dev/null +++ b/apps/datahub-e2e/src/fixtures/covoit-mel.json @@ -0,0 +1,44 @@ +{ + "id": "covoit-mel", + "title": "covoit-mel", + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=geojson", + "rel": "items", + "type": "application/geo+json", + "title": "covoit-mel" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=json&limit=-1", + "rel": "enclosure", + "type": "application/json", + "title": "Bulk download (JSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=geojson&limit=-1", + "rel": "enclosure", + "type": "application/geo+json", + "title": "Bulk download (GeoJSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=shapefile&limit=-1", + "rel": "enclosure", + "type": "application/x-shapefile", + "title": "Bulk download (Esri Shapefile)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=csv&limit=-1", + "rel": "enclosure", + "type": "text/csv;charset=UTF-8", + "title": "Bulk download (Comma Separated Values)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=ooxml&limit=-1", + "rel": "enclosure", + "type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "title": "Bulk download (Excel 2007 / OOXML)" + } + ], + "itemType": "feature", + "crs": ["http://www.opengis.net/def/crs/OGC/1.3/CRS84"] +} diff --git a/apps/datahub-e2e/src/fixtures/covoit-mel_items.json b/apps/datahub-e2e/src/fixtures/covoit-mel_items.json new file mode 100644 index 0000000000..b0bd1b8b44 --- /dev/null +++ b/apps/datahub-e2e/src/fixtures/covoit-mel_items.json @@ -0,0 +1,248 @@ +{ + "numberMatched": 10, + "numberReturned": 10, + "records": [ + { + "@id": "1", + "id_lieu": "97412-C-774", + "id_local": 15578, + "nom_lieu": "1 Chemin Auguste Boyer", + "ad_lieu": null, + "com_lieu": "Saint-Joseph", + "insee": 97412, + "type": "Auto-stop", + "date_maj": "2022-04-25", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "2", + "id_lieu": "97422-C-290", + "id_local": 19545, + "nom_lieu": "1 Chemin Commerson", + "ad_lieu": null, + "com_lieu": "Le Tampon", + "insee": 97422, + "type": "Auto-stop", + "date_maj": "2022-04-26", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "3", + "id_lieu": "97422-C-291", + "id_local": 19546, + "nom_lieu": "1 Chemin Commerson", + "ad_lieu": null, + "com_lieu": "Le Tampon", + "insee": 97422, + "type": "Auto-stop", + "date_maj": "2022-04-26", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "4", + "id_lieu": "97404-C-058", + "id_local": 17935, + "nom_lieu": "1 Chemin Neuf", + "ad_lieu": null, + "com_lieu": "L'Étang-Salé", + "insee": 97404, + "type": "Auto-stop", + "date_maj": "2022-04-26", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "5", + "id_lieu": "97404-C-089", + "id_local": 17966, + "nom_lieu": "1 Chemin Neuf", + "ad_lieu": null, + "com_lieu": "L'Étang-Salé", + "insee": 97404, + "type": "Auto-stop", + "date_maj": "2022-04-26", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "6", + "id_lieu": "97422-C-233", + "id_local": 19488, + "nom_lieu": "1 Chemin Notre Dame De La Paix", + "ad_lieu": null, + "com_lieu": "Le Tampon", + "insee": 97422, + "type": "Auto-stop", + "date_maj": "2022-04-26", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "7", + "id_lieu": "97422-C-282", + "id_local": 19537, + "nom_lieu": "1 Chemin Notre Dame De La Paix", + "ad_lieu": null, + "com_lieu": "Le Tampon", + "insee": 97422, + "type": "Auto-stop", + "date_maj": "2022-04-26", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "8", + "id_lieu": "97422-C-560", + "id_local": 15648, + "nom_lieu": "1 Chemin Notre Dame De La Paix", + "ad_lieu": null, + "com_lieu": "Le Tampon", + "insee": 97422, + "type": "Auto-stop", + "date_maj": "2022-04-25", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "9", + "id_lieu": "97422-C-564", + "id_local": 15652, + "nom_lieu": "1 Chemin Notre Dame De La Paix", + "ad_lieu": null, + "com_lieu": "Le Tampon", + "insee": 97422, + "type": "Auto-stop", + "date_maj": "2022-04-25", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + }, + { + "@id": "10", + "id_lieu": "97416-C-175", + "id_local": 17037, + "nom_lieu": "1 Chemin Terre Des Chênes", + "ad_lieu": null, + "com_lieu": "Saint-Pierre", + "insee": 97416, + "type": "Auto-stop", + "date_maj": "2022-04-26", + "ouvert": "true", + "source": 810157982, + "nbre_pl": null, + "nbre_pmr": null, + "duree": null, + "horaires": null, + "proprio": null, + "lumiere": "false", + "comm": null + } + ], + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=json", + "rel": "self", + "type": "application/json", + "hreflang": null, + "title": "This document", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=geojson", + "rel": "alternate", + "type": "application/geo+json", + "hreflang": null, + "title": "This document as GeoJSON", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=shapefile", + "rel": "alternate", + "type": "application/x-shapefile", + "hreflang": null, + "title": "This document as Esri Shapefile", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=csv", + "rel": "alternate", + "type": "text/csv;charset=UTF-8", + "hreflang": null, + "title": "This document as Comma Separated Values", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=ooxml", + "rel": "alternate", + "type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "hreflang": null, + "title": "This document as Excel 2007 / OOXML", + "length": null + } + ] +} diff --git a/apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix.json b/apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix.json new file mode 100644 index 0000000000..dbe7369594 --- /dev/null +++ b/apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix.json @@ -0,0 +1,44 @@ +{ + "id": "liste-des-jardins-familiaux-et-partages-de-roubaix", + "title": "liste-des-jardins-familiaux-et-partages-de-roubaix", + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=geojson", + "rel": "items", + "type": "application/geo+json", + "title": "liste-des-jardins-familiaux-et-partages-de-roubaix" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=json&limit=-1", + "rel": "enclosure", + "type": "application/json", + "title": "Bulk download (JSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=geojson&limit=-1", + "rel": "enclosure", + "type": "application/geo+json", + "title": "Bulk download (GeoJSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=shapefile&limit=-1", + "rel": "enclosure", + "type": "application/x-shapefile", + "title": "Bulk download (Esri Shapefile)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=csv&limit=-1", + "rel": "enclosure", + "type": "text/csv;charset=UTF-8", + "title": "Bulk download (Comma Separated Values)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=ooxml&limit=-1", + "rel": "enclosure", + "type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "title": "Bulk download (Excel 2007 / OOXML)" + } + ], + "itemType": "feature", + "crs": ["http://www.opengis.net/def/crs/OGC/1.3/CRS84"] +} diff --git a/apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix_items.json b/apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix_items.json new file mode 100644 index 0000000000..c8c8bff3da --- /dev/null +++ b/apps/datahub-e2e/src/fixtures/liste-des-jardins-familiaux-et-partages-de-roubaix_items.json @@ -0,0 +1,136 @@ +{ + "numberMatched": 41, + "numberReturned": 10, + "records": [ + { + "@id": "1", + "nom": "Luxembourg", + "adresse": "Rue du Luxembourg", + "OBJECTID": 1, + "geo_shape": "{\"coordinates\": [3.1520091516295423, 50.68782872872605], \"type\": \"Point\"}", + "geo_point_2d": "50.68782872872605, 3.1520091516295423" + }, + { + "@id": "2", + "nom": "Brondeloire", + "adresse": "38 rue du Brondeloire", + "OBJECTID": 2, + "geo_shape": "{\"coordinates\": [3.158070964759599, 50.690337919553706], \"type\": \"Point\"}", + "geo_point_2d": "50.690337919553706, 3.158070964759599" + }, + { + "@id": "3", + "nom": "Rome", + "adresse": "68 bis Rue de Rome", + "OBJECTID": 5, + "geo_shape": "{\"coordinates\": [3.158815444373721, 50.695729149252635], \"type\": \"Point\"}", + "geo_point_2d": "50.695729149252635, 3.158815444373721" + }, + { + "@id": "4", + "nom": "Alma", + "adresse": "226 Rue de l'Alma", + "OBJECTID": 7, + "geo_shape": "{\"coordinates\": [3.170914706775103, 50.70016060535821], \"type\": \"Point\"}", + "geo_point_2d": "50.70016060535821, 3.170914706775103" + }, + { + "@id": "5", + "nom": "Bord de canal", + "adresse": "Quai de Toulon et Quai de Rouen", + "OBJECTID": 10, + "geo_shape": "{\"coordinates\": [3.188111428412068, 50.69786556339497], \"type\": \"Point\"}", + "geo_point_2d": "50.69786556339497, 3.188111428412068" + }, + { + "@id": "6", + "nom": "Marceau", + "adresse": "1 Rue Marceau", + "OBJECTID": 12, + "geo_shape": "{\"coordinates\": [3.1938923087141933, 50.690492700879766], \"type\": \"Point\"}", + "geo_point_2d": "50.690492700879766, 3.1938923087141933" + }, + { + "@id": "7", + "nom": "Fontier", + "adresse": "60 Rue de Denain", + "OBJECTID": 15, + "geo_shape": "{\"coordinates\": [3.178030581032674, 50.68327981740213], \"type\": \"Point\"}", + "geo_point_2d": "50.68327981740213, 3.178030581032674" + }, + { + "@id": "8", + "nom": "Artois", + "adresse": "8 Rue d'Artois", + "OBJECTID": 17, + "geo_shape": "{\"coordinates\": [3.1858945557217004, 50.68116568357998], \"type\": \"Point\"}", + "geo_point_2d": "50.68116568357998, 3.1858945557217004" + }, + { + "@id": "9", + "nom": "Hauts Champs", + "adresse": "rue Jean Baptiste Chardin", + "OBJECTID": 415, + "geo_shape": "{\"coordinates\": [3.196147408905368, 50.67386486034824], \"type\": \"Point\"}", + "geo_point_2d": "50.67386486034824, 3.196147408905368" + }, + { + "@id": "10", + "nom": "Vivier", + "adresse": "Rue des arts", + "OBJECTID": 3, + "geo_shape": "{\"coordinates\": [3.1598916392041674, 50.69160592869598], \"type\": \"Point\"}", + "geo_point_2d": "50.69160592869598, 3.1598916392041674" + } + ], + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=json", + "rel": "self", + "type": "application/json", + "hreflang": null, + "title": "This document", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=json&offset=10&limit=10", + "rel": "next", + "type": "application/json", + "hreflang": null, + "title": "Next page", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=geojson", + "rel": "alternate", + "type": "application/geo+json", + "hreflang": null, + "title": "This document as GeoJSON", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=shapefile", + "rel": "alternate", + "type": "application/x-shapefile", + "hreflang": null, + "title": "This document as Esri Shapefile", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=csv", + "rel": "alternate", + "type": "text/csv;charset=UTF-8", + "hreflang": null, + "title": "This document as Comma Separated Values", + "length": null + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=ooxml", + "rel": "alternate", + "type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "hreflang": null, + "title": "This document as Excel 2007 / OOXML", + "length": null + } + ] +} diff --git a/apps/datahub-e2e/src/fixtures/ogcapi.json b/apps/datahub-e2e/src/fixtures/ogcapi.json new file mode 100644 index 0000000000..9ee985d994 --- /dev/null +++ b/apps/datahub-e2e/src/fixtures/ogcapi.json @@ -0,0 +1,36 @@ +{ + "title": "geOrchestra Data API", + "description": "data-api provides an API to access datas", + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/", + "rel": "self", + "type": "application/json", + "title": "This document as JSON" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/conformance", + "rel": "conformance", + "type": "application/json", + "title": "Conformance" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections", + "rel": "data", + "type": "application/json", + "title": "Collections" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/../v3/api-docs", + "rel": "service-desc", + "type": "application/vnd.oai.openapi+json;version=3.0", + "title": "OpenAPI definition in JSON format" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/../swagger-ui/index.html", + "rel": "service-doc", + "type": "text/html", + "title": "OpenAPI definition in HTML format" + } + ] +} diff --git a/apps/datahub-e2e/src/fixtures/ogcapi_collections.json b/apps/datahub-e2e/src/fixtures/ogcapi_collections.json new file mode 100644 index 0000000000..d1f2415cbf --- /dev/null +++ b/apps/datahub-e2e/src/fixtures/ogcapi_collections.json @@ -0,0 +1,129 @@ +{ + "collections": [ + { + "id": "covoit-mel", + "title": "covoit-mel", + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=geojson", + "rel": "items", + "type": "application/geo+json", + "title": "covoit-mel" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=json&limit=-1", + "rel": "enclosure", + "type": "application/json", + "title": "Bulk download (JSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=geojson&limit=-1", + "rel": "enclosure", + "type": "application/geo+json", + "title": "Bulk download (GeoJSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=shapefile&limit=-1", + "rel": "enclosure", + "type": "application/x-shapefile", + "title": "Bulk download (Esri Shapefile)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=csv&limit=-1", + "rel": "enclosure", + "type": "text/csv;charset=UTF-8", + "title": "Bulk download (Comma Separated Values)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/covoit-mel/items?f=ooxml&limit=-1", + "rel": "enclosure", + "type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "title": "Bulk download (Excel 2007 / OOXML)" + } + ], + "itemType": "feature", + "crs": ["http://www.opengis.net/def/crs/OGC/1.3/CRS84"] + }, + { + "id": "geopackages_to_delete", + "title": "geopackages_to_delete", + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/geopackages_to_delete/items?f=geojson", + "rel": "items", + "type": "application/geo+json", + "title": "geopackages_to_delete" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/geopackages_to_delete/items?f=json&limit=-1", + "rel": "enclosure", + "type": "application/json", + "title": "Bulk download (JSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/geopackages_to_delete/items?f=geojson&limit=-1", + "rel": "enclosure", + "type": "application/geo+json", + "title": "Bulk download (GeoJSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/geopackages_to_delete/items?f=csv&limit=-1", + "rel": "enclosure", + "type": "text/csv;charset=UTF-8", + "title": "Bulk download (Comma Separated Values)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/geopackages_to_delete/items?f=ooxml&limit=-1", + "rel": "enclosure", + "type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "title": "Bulk download (Excel 2007 / OOXML)" + } + ], + "itemType": "record" + }, + { + "id": "liste-des-jardins-familiaux-et-partages-de-roubaix", + "title": "liste-des-jardins-familiaux-et-partages-de-roubaix", + "links": [ + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=geojson", + "rel": "items", + "type": "application/geo+json", + "title": "liste-des-jardins-familiaux-et-partages-de-roubaix" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=json&limit=-1", + "rel": "enclosure", + "type": "application/json", + "title": "Bulk download (JSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=geojson&limit=-1", + "rel": "enclosure", + "type": "application/geo+json", + "title": "Bulk download (GeoJSON)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=shapefile&limit=-1", + "rel": "enclosure", + "type": "application/x-shapefile", + "title": "Bulk download (Esri Shapefile)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=csv&limit=-1", + "rel": "enclosure", + "type": "text/csv;charset=UTF-8", + "title": "Bulk download (Comma Separated Values)" + }, + { + "href": "https://mel.integration.apps.gs-fr-prod.camptocamp.com/data/ogcapi/collections/liste-des-jardins-familiaux-et-partages-de-roubaix/items?f=ooxml&limit=-1", + "rel": "enclosure", + "type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", + "title": "Bulk download (Excel 2007 / OOXML)" + } + ], + "itemType": "feature", + "crs": ["http://www.opengis.net/def/crs/OGC/1.3/CRS84"] + } + ] +} diff --git a/apps/datahub-e2e/src/fixtures/ogcapi_conformance.json b/apps/datahub-e2e/src/fixtures/ogcapi_conformance.json new file mode 100644 index 0000000000..ebdc784bf7 --- /dev/null +++ b/apps/datahub-e2e/src/fixtures/ogcapi_conformance.json @@ -0,0 +1,18 @@ +{ + "conformsTo": [ + "http://www.opengis.net/spec/ogcapi-features-1/1.0/req/oas30", + "http://www.opengis.net/spec/ogcapi-common-1/1.0/conf/json", + "http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/core", + "http://www.opengis.net/spec/ogcapi-common-1/1.0/conf/oas30", + "http://www.opengis.net/spec/ogcapi-common-1/1.0/conf/landing-page", + "http://www.opengis.net/spec/ogcapi-features-2/1.0/conf/crs", + "http://www.opengis.net/spec/ogcapi-common-2/1.0/conf/collections", + "http://www.opengis.net/spec/ogcapi-features-5/1.0/conf/schemas", + "http://www.opengis.net/spec/ogcapi-features-3/1.0/conf/queryables", + "http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/geojson", + "http://www.opengis.net/spec/ogcapi-features-3/1.0/conf/queryables-query-parameters", + "http://www.opengis.net/spec/ogcapi-common-1/1.0/conf/core", + "http://www.opengis.net/spec/ogcapi-features-5/1.0/req/core-roles-features", + "http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/html" + ] +}