name: Server tests on: push: paths: - "Overlord-Server/**" - "Overlord-Client/cmd/agent/wire/wire_contract_generated.go" - "protocol/**" - "scripts/generate-wire-protocol.ts" - ".gitea/workflows/server-tests.yml" pull_request: paths: - "Overlord-Server/**" - "Overlord-Client/cmd/agent/wire/wire_contract_generated.go" - "protocol/**" - "scripts/generate-wire-protocol.ts" - ".gitea/workflows/server-tests.yml" workflow_dispatch: permissions: contents: read jobs: unit: runs-on: ubuntu-latest defaults: run: working-directory: Overlord-Server steps: - name: Checkout repository uses: https://github.com/actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 - name: Set up Bun uses: https://github.com/oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2 with: bun-version: 1.3.14 - name: Install dependencies run: bun install --frozen-lockfile - name: Typecheck run: bun run typecheck - name: Verify generated wire protocol run: bun run protocol:check - name: Run unit tests run: bun run test browser: runs-on: ubuntu-latest defaults: run: working-directory: Overlord-Server steps: - name: Checkout repository uses: https://github.com/actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 - name: Set up Bun uses: https://github.com/oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2 with: bun-version: 1.3.14 - name: Install dependencies run: bun install --frozen-lockfile - name: Install Chromium and system dependencies run: bunx playwright install --with-deps chromium - name: Run browser tests run: bun run test:e2e