From 81d75ef0810ca068fbacc2a13d71d1645d53a5c5 Mon Sep 17 00:00:00 2001 From: Tobias Kohr Date: Tue, 7 May 2024 09:39:29 +0200 Subject: [PATCH] feat(footer): open icon links in new tab --- apps/home-e2e/src/e2e/home.cy.ts | 10 +++++++++- .../src/lib/footer/mel-datahub-footer.component.html | 4 ++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/apps/home-e2e/src/e2e/home.cy.ts b/apps/home-e2e/src/e2e/home.cy.ts index ab75da6d..a4c15538 100644 --- a/apps/home-e2e/src/e2e/home.cy.ts +++ b/apps/home-e2e/src/e2e/home.cy.ts @@ -85,7 +85,7 @@ describe('home', () => { cy.get('@url').should('include', 'twitter') cy.get('@url').should('include', 'MetropoleLille') }) - it('should display the partners icons', () => { + it('should display the partners icons as links', () => { cy.get('@footer') .children('footer') .first() @@ -95,6 +95,14 @@ describe('home', () => { .eq(1) .children('a') .should('have.length', 2) + .each((el, index) => { + const urls = [ + 'https://next-generation-eu.europa.eu/index_fr', + 'https://www.economie.gouv.fr/plan-de-relance', + ] + cy.wrap(el).should('have.attr', 'href', urls[index]) + cy.wrap(el).should('have.attr', 'target', '_blank') + }) }) it('should have a button to the newsletter subscription', () => { cy.get('@footer') diff --git a/libs/mel/src/lib/footer/mel-datahub-footer.component.html b/libs/mel/src/lib/footer/mel-datahub-footer.component.html index 71911780..49f1aa48 100644 --- a/libs/mel/src/lib/footer/mel-datahub-footer.component.html +++ b/libs/mel/src/lib/footer/mel-datahub-footer.component.html @@ -129,14 +129,14 @@
- + - +