feat(ui): icônes botaniques par espèce #82
Workflow file for this run
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: Tests | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| services: | |
| postgres: | |
| image: postgis/postgis:16-3.4-alpine | |
| env: | |
| POSTGRES_PASSWORD: gleba_test | |
| POSTGRES_DB: gleba_test | |
| ports: | |
| - 5432:5432 | |
| options: >- | |
| --health-cmd "pg_isready -U postgres -d gleba_test" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup Node.js 20 | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: "20" | |
| cache: "npm" | |
| - name: Install dependencies | |
| # legacy-peer-deps pour cohabitation Shepherd.js / cmdk / react 18 | |
| run: npm ci --legacy-peer-deps | |
| - name: Generate Prisma client | |
| run: npx prisma generate | |
| env: | |
| # URL bidon : on n'a pas besoin de connexion DB pour `prisma generate` | |
| DATABASE_URL: "postgresql://x:x@localhost:5432/x" | |
| - name: Validate fresh database bootstrap | |
| run: | | |
| npx prisma migrate deploy | |
| npx tsx prisma/seed.ts | |
| npx tsx scripts/verify-bootstrap.ts | |
| env: | |
| DATABASE_URL: "postgresql://postgres:gleba_test@localhost:5432/gleba_test" | |
| ADMIN_EMAIL: "admin@example.test" | |
| ADMIN_NAME: "Test Admin" | |
| ADMIN_PASSWORD: "ci-only-password" | |
| - name: Lint quality gate | |
| run: npm run lint:ci -- --base "$LINT_BASE_SHA" | |
| env: | |
| # PR: compare aux lignes ajoutées depuis la branche cible. | |
| # Push: compare au commit précédant le push; la baseline protège aussi le total. | |
| LINT_BASE_SHA: ${{ github.event.pull_request.base.sha || github.event.before }} | |
| - name: Run vitest | |
| run: npm test | |
| - name: Type check | |
| run: npx tsc --noEmit |