Self-Hosted CI #6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Self-Hosted CI | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| # Ajout d'un déclencheur manuel pour faciliter les tests | |
| workflow_dispatch: | |
| jobs: | |
| build-and-test: | |
| # Spécifie d'utiliser votre runner auto-hébergé au lieu des runners GitHub | |
| runs-on: self-hosted | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| - name: Log Node.js version | |
| run: node --version | |
| # ÉTAPE SUPPRIMÉE - pas critique pour le TP (df -h ne marche pas sur Windows) | |
| - name: Install dependencies | |
| run: npm ci --legacy-peer-deps | |
| - name: Run tests | |
| run: npm test -- --watch=false --browsers=ChromeHeadless --no-progress |