From 7d2aad0985d3ec7d617f2d639e97235f68a839f9 Mon Sep 17 00:00:00 2001 From: Martial Maillot Date: Wed, 7 Aug 2024 13:57:54 +0200 Subject: [PATCH] =?UTF-8?q?fix(e2e):=20utilisation=20du=20sitemap=20pour?= =?UTF-8?q?=20g=C3=A9n=C3=A9rer=20les=20tests=20e2e=20(#6063)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../cypress/integration/light/validate-html.spec.ts | 6 +----- packages/code-du-travail-frontend/cypress/support/before.ts | 6 +++--- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/packages/code-du-travail-frontend/cypress/integration/light/validate-html.spec.ts b/packages/code-du-travail-frontend/cypress/integration/light/validate-html.spec.ts index c192e5ee16..a3941cad4e 100644 --- a/packages/code-du-travail-frontend/cypress/integration/light/validate-html.spec.ts +++ b/packages/code-du-travail-frontend/cypress/integration/light/validate-html.spec.ts @@ -1,9 +1,5 @@ import "cypress-html-validate/commands"; - -import urls from "../../support/urls-to-validate.json"; -import { ConfigData } from "cypress-html-validate"; -import {localConfig} from "../heavy/validate-html.spec"; - +import { localConfig } from "../heavy/validate-html.spec"; describe("Validation de l'html d'un échantillon de pages", () => { [ diff --git a/packages/code-du-travail-frontend/cypress/support/before.ts b/packages/code-du-travail-frontend/cypress/support/before.ts index bb08ec0d16..1ce6d39df8 100644 --- a/packages/code-du-travail-frontend/cypress/support/before.ts +++ b/packages/code-du-travail-frontend/cypress/support/before.ts @@ -27,14 +27,14 @@ export const downloadAllUrlsToValidate = async () => { JSON.stringify( urls.filter( (url) => - url.includes("/information") || - url.includes("/convention-collective") + url.includes("/information/") || + url.includes("/convention-collective/") ) ) ); const urlsContributions: string[] = urls.filter((url) => - url.includes("/contribution") + url.includes("/contribution/") ); fs.writeFileSync(