chore: reallocate blocked supply-chain-integrity 5 pts into security signals (IN-1250) #958
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: Server Tests | |
| on: | |
| pull_request: | |
| # Only trigger when relevant files change to save CI minutes | |
| paths-ignore: | |
| - 'frontend/**' | |
| - '**.md' | |
| - '.gitignore' | |
| - '.editorconfig' | |
| - '**/.eslintrc*' | |
| - '.prettierrc' | |
| - '.prettierignore' | |
| - 'LICENSE' | |
| # Automatically cancel in-progress runs if you push new code to the same PR | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
| cancel-in-progress: true | |
| permissions: | |
| contents: read | |
| actions: write # GHA cache for Flyway image layers | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 30 | |
| services: | |
| postgres: | |
| image: postgres:14-alpine | |
| command: postgres -c wal_level=logical | |
| env: | |
| POSTGRES_USER: postgres | |
| POSTGRES_PASSWORD: example | |
| POSTGRES_DB: postgres | |
| ports: | |
| - 5432:5432 | |
| options: >- | |
| --health-cmd "pg_isready -U postgres" | |
| --health-interval 2s | |
| --health-timeout 5s | |
| --health-retries 15 | |
| env: | |
| NODE_ENV: test | |
| DB_HOST: localhost | |
| DB_PORT: 5432 | |
| DB_USER: postgres | |
| DB_PASSWORD: example | |
| steps: | |
| - name: Check out repository code | |
| uses: actions/checkout@v4 | |
| - name: Setup pnpm and node | |
| uses: pnpm/setup@84cb39b217b10273981911c288cd62326dc7c6d2 # v2.0.2 | |
| with: | |
| runtime: node@24 | |
| cache: true | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Build Flyway image | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: backend/src/database | |
| file: backend/src/database/Dockerfile.flyway | |
| load: true | |
| tags: crowd_flyway | |
| cache-from: type=gha,scope=flyway | |
| cache-to: type=gha,mode=max,scope=flyway | |
| - name: Prepare test database | |
| env: | |
| SKIP_FLYWAY_BUILD: 1 | |
| run: ./.github/scripts/prepare-test-template-db.sh | |
| - name: Run server tests | |
| run: pnpm test:server |