Skip to content

Merge pull request #26 from BriefHQ/license #114

Merge pull request #26 from BriefHQ/license

Merge pull request #26 from BriefHQ/license #114

name: Test & Build
on:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
- cron: "12 16 * * *"
jobs:
test-and-build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x, 20.x]
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: 9
run_install: false
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Install zero canary (cron only)
if: github.event_name == 'schedule'
run: pnpm install @rocicorp/zero@canary -w
- name: Build
run: pnpm run build
- name: Type check tests
run: pnpm run test:types
- name: Run tests
run: pnpm test
- name: Run integration tests (PG 16)
run: cd integration && PG_VERSION=16 pnpm test
- name: Run integration tests (PG 17)
run: cd integration && PG_VERSION=17 pnpm test