From cf72cb1fe71533b3c172868d6e974c8433ef0a6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Gonz=C3=A1lez=20Mu=C3=B1oz?= Date: Mon, 10 Jun 2024 11:41:48 +0200 Subject: [PATCH] fixes e2e test --- .../cypress/e2e/analysis/filters-table.cy.ts | 4 +- client/cypress/fixtures/indicators/index.json | 70 +++++++++---------- 2 files changed, 37 insertions(+), 37 deletions(-) diff --git a/client/cypress/e2e/analysis/filters-table.cy.ts b/client/cypress/e2e/analysis/filters-table.cy.ts index 82d03ce0e..6ba9378a4 100644 --- a/client/cypress/e2e/analysis/filters-table.cy.ts +++ b/client/cypress/e2e/analysis/filters-table.cy.ts @@ -98,11 +98,11 @@ describe('Analysis filters', () => { $tableRows.first().find('button').contains('View detail').click(); - $tableHeader.contains(waterQuality[0].attributes.name); + $tableHeader.contains(waterQuality[1].attributes.name); cy.url().should( 'include', - `indicators=${waterQuality.map(({ id }) => id).join(',')}&detail=${waterQuality[0].id}`, + `indicators=${waterQuality.map(({ id }) => id).join(',')}&detail=${waterQuality[1].id}`, ); }); }); diff --git a/client/cypress/fixtures/indicators/index.json b/client/cypress/fixtures/indicators/index.json index 410b070a3..274bdd460 100644 --- a/client/cypress/fixtures/indicators/index.json +++ b/client/cypress/fixtures/indicators/index.json @@ -80,6 +80,41 @@ "nameCode": "DF_SLUC" } }, + { + "type": "indicators", + "id": "d5f945c9-8636-45a2-a7c9-67a1dc8e687a", + "attributes": { + "id": "d5f945c9-8636-45a2-a7c9-67a1dc8e687a", + "name": "Freshwater nutrient load assimilation volume", + "description": "The freshwater nutrient load assimilation volume indicator estimates the annual average water volume required to assimilate the nutrient load added by the raw material sourced.", + "category": "Water quality", + "status": "active", + "metadata": { + "name": "Freshwater nutrient load assimilation volume", + "units": "Mm3/yr", + "source": [ + "Mekonnen 2011", + "Mekonnen 2012" + ], + "license": "CC BY 4.0", + "citation": [ + "Mekonnen, M.M. & Hoekstra, A.Y. (2011) The green, blue and grey water footprint of crops and derived crop products, Hydrology and Earth System Sciences, 15(5): 1577-1600.", + "Mekonnen, M.M. & Hoekstra, A.Y. (2012) A global assessment of the water footprint of farm animal products, Ecosystems, 15(3): 401–415." + ], + "name_code": "NL", + "resolution": "", + "short_name": "Nutrient load", + "description": "The freshwater nutrient load assimilation volume indicator estimates the annual average water volume required to assimilate the nutrient load added by the raw material sourced.", + "indicator_type": "farm-level", + "interpretation": "The nutrient load indicator describes the average volume of freshwater required to absorb the nutrient load created by production of the raw material. It is intended to align with the Science Based Targets Network (SBTN) water quality target indicator (Science Based Targets Network 2023b).", + "date_of_content": "1996-2005", + "geographic_coverage": "Global coverage.", + "frequency_of_updates": "", + "impact_type_category": "Water quality" + }, + "nameCode": "NL" + } + }, { "type": "indicators", "id": "a39394be-ad57-41bc-9c2c-be0949ec6193", @@ -155,41 +190,6 @@ "nameCode": "UWU" } }, - { - "type": "indicators", - "id": "d5f945c9-8636-45a2-a7c9-67a1dc8e687a", - "attributes": { - "id": "d5f945c9-8636-45a2-a7c9-67a1dc8e687a", - "name": "Freshwater nutrient load assimilation volume", - "description": "The freshwater nutrient load assimilation volume indicator estimates the annual average water volume required to assimilate the nutrient load added by the raw material sourced.", - "category": "Water quality", - "status": "active", - "metadata": { - "name": "Freshwater nutrient load assimilation volume", - "units": "Mm3/yr", - "source": [ - "Mekonnen 2011", - "Mekonnen 2012" - ], - "license": "CC BY 4.0", - "citation": [ - "Mekonnen, M.M. & Hoekstra, A.Y. (2011) The green, blue and grey water footprint of crops and derived crop products, Hydrology and Earth System Sciences, 15(5): 1577-1600.", - "Mekonnen, M.M. & Hoekstra, A.Y. (2012) A global assessment of the water footprint of farm animal products, Ecosystems, 15(3): 401–415." - ], - "name_code": "NL", - "resolution": "", - "short_name": "Nutrient load", - "description": "The freshwater nutrient load assimilation volume indicator estimates the annual average water volume required to assimilate the nutrient load added by the raw material sourced.", - "indicator_type": "farm-level", - "interpretation": "The nutrient load indicator describes the average volume of freshwater required to absorb the nutrient load created by production of the raw material. It is intended to align with the Science Based Targets Network (SBTN) water quality target indicator (Science Based Targets Network 2023b).", - "date_of_content": "1996-2005", - "geographic_coverage": "Global coverage.", - "frequency_of_updates": "", - "impact_type_category": "Water quality" - }, - "nameCode": "NL" - } - }, { "type": "indicators", "id": "9c2124c7-5df0-40d5-962e-d35480d48cd3",