From ba11b0bbc7236ea1b2650beebc9b85bfed9485a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rados=C5=82aw=20Dobies?= Date: Tue, 10 Nov 2026 11:08:06 +0100 Subject: [PATCH] ci: run build, type check and tests on pull requests --- .github/workflows/ci.yml | 47 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..9254edd --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,47 @@ +name: CI + +on: + pull_request: + push: + branches: + - main + +permissions: + contents: read + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: ${{ github.event_name == 'pull_request' }} + +jobs: + check: + runs-on: ubuntu-latest + timeout-minutes: 15 + steps: + - uses: actions/checkout@v4 + + - uses: oven-sh/setup-bun@v2 + with: + bun-version: "1.4.3" + + - uses: actions/setup-node@v4 + with: + node-version: "22" + + - name: Install dependencies + run: bun install --frozen-lockfile + + # Build before the type check: tsconfig.json `paths` does not map every + # package, so `tsc` resolves some @data-slot/* imports through their + # built dist/*.d.ts files. + - name: Build packages + run: bun run build + + - name: Type check + run: bun run typecheck + + - name: Run tests + run: bun test + + - name: Verify published UI exports + run: bun run test:ui:published