Skip to content

Commit

Permalink
fix(e2e): ajout des tests dans les sous dossiers (#5879)
Browse files Browse the repository at this point in the history
  • Loading branch information
m-maillot committed May 14, 2024
1 parent 82db7d7 commit 682fce9
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 7 deletions.
22 changes: 16 additions & 6 deletions .github/workflows/e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,22 @@ jobs:
name: e2e-screenshots
path: |
packages/code-du-travail-frontend/cypress/screenshots
- name: Create the Mattermost Message
if: failure()
run: |
echo "{\"text\":\"Les tests automatiques e2e ont échoué sur la pré-prod. Reportez-vous à ce run : ${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID} (cc: @max @victorz @carolinebda @martial)\"}" > mattermost.json
- name: Send message to mattermost if failure
uses: mattermost/action-mattermost-notify@master
- name: Send message to mattermost when done
uses: mattermost/action-mattermost-notify@v2.0.0
if: always()
with:
MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
PAYLOAD: |-
{
"text": "Les tests automatiques e2e sont terminés: **${{ job.status }}**. Détails : ${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}",
}
- name: Ping the team when failed
uses: mattermost/action-mattermost-notify@v2.0.0
if: failure()
with:
MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
PAYLOAD: |-
{
"text": "Tests e2e en échec @max @victorz @carolinebda @martial :scream:",
}
2 changes: 1 addition & 1 deletion packages/code-du-travail-frontend/cypress.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = defineConfig({
baseUrl: process.env.TEST_BASEURL ?? "http://localhost:3000",
specPattern: process.env.ALL_TEST
? "cypress/integration/**/*.spec.{js,jsx,ts,tsx}"
: "cypress/integration/light/*.spec.{js,jsx,ts,tsx}",
: "cypress/integration/light/**/*.spec.{js,jsx,ts,tsx}",
supportFile: "cypress/support/index.ts",
viewportHeight: 1000,
viewportWidth: 1280,
Expand Down

0 comments on commit 682fce9

Please sign in to comment.