From b24aaaa1351ca7fa091d524c37ea0b1716b108dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Gonz=C3=A1lez?= Date: Tue, 14 May 2024 18:47:29 +0200 Subject: [PATCH] updates tests --- client/cypress/e2e/analysis/filters-map.cy.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/client/cypress/e2e/analysis/filters-map.cy.ts b/client/cypress/e2e/analysis/filters-map.cy.ts index a6921d021..893b9ccae 100644 --- a/client/cypress/e2e/analysis/filters-map.cy.ts +++ b/client/cypress/e2e/analysis/filters-map.cy.ts @@ -1,8 +1,5 @@ describe('Analysis filters', () => { beforeEach(() => { - // cy.intercept('GET', '/api/v1/indicators?sort=name', { - // fixture: 'indicators/index', - // }).as('fetchIndicators'); cy.intercept('GET', '/api/v1/indicators*', { fixture: 'indicators/index', }).as('fetchActiveIndicators'); @@ -32,7 +29,7 @@ describe('Analysis filters', () => { const firstIndicator = interception.response.body?.data[0]; cy.get('[data-testid="select-indicators-filter"]').should( 'contain', - firstIndicator?.attributes.name, + firstIndicator?.attributes.metadata.short_name, ); cy.url().should('include', `indicators=${firstIndicator?.id}`); }); @@ -43,7 +40,7 @@ describe('Analysis filters', () => { const thirdIndicator = interception.response.body?.data[2]; cy.get('[data-testid="select-indicators-filter"]') .type('{downarrow}{downarrow}{enter}') - .should('contain', thirdIndicator?.attributes.name); + .should('contain', thirdIndicator?.attributes.metadata.short_name); cy.url().should('include', `indicators=${thirdIndicator?.id}`); }); });