[Test] Prove the inventory store's races and crash seams over real storage on both dialects #386
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: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| # Cancel a PR's superseded runs when new commits land; never cancel an | |
| # in-flight main-branch validation (each merge should finish its own check). | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.event_name == 'pull_request' }} | |
| jobs: | |
| unit: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: "22" | |
| cache: pnpm | |
| - run: pnpm install --frozen-lockfile | |
| # Domain purity is a CI gate (dependency-cruiser domain-is-io-free). | |
| - run: pnpm lint | |
| # The branded-money negative type-test is enforced here. | |
| - run: pnpm typecheck | |
| # Per-package typecheck for workspaces outside root tsc -b (the | |
| # sites/* Astro packages typecheck with `astro check`). | |
| - run: pnpm -r --if-present typecheck | |
| - run: pnpm -r build | |
| # SQLite + fake contract suites; pg-required specs self-skip | |
| # because PG_CONNECTION_STRING is unset. | |
| - run: pnpm test | |
| integration: | |
| needs: unit | |
| runs-on: ubuntu-latest | |
| services: | |
| postgres: | |
| image: postgres:16 | |
| env: | |
| POSTGRES_PASSWORD: postgres | |
| POSTGRES_DB: otta_test | |
| ports: | |
| - 5432:5432 | |
| options: >- | |
| --health-cmd pg_isready | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| env: | |
| PG_CONNECTION_STRING: postgres://postgres:postgres@localhost:5432/otta_test | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: "22" | |
| cache: pnpm | |
| - run: pnpm install --frozen-lockfile | |
| # Scoped to the files that actually touch Postgres (scripts/pg-test-files.sh) — | |
| # the sqlite/fake-only suite already ran in `unit`, no need to redo it here. | |
| - run: pnpm test:pg |