feat: add domformat package and canonical gallery corpus #195
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: | |
| pull_request: | |
| branches: | |
| - main | |
| push: | |
| branches: | |
| - main | |
| concurrency: | |
| group: ci-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| test-and-build: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Check out | |
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 | |
| - name: Set up pnpm | |
| uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda | |
| with: | |
| version: 10.32.1 | |
| - name: Set up Node | |
| uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 | |
| with: | |
| node-version: 22 | |
| cache: pnpm | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Run tests | |
| run: pnpm test | |
| - name: Enforce Morph coverage | |
| run: pnpm --filter @layoutit/polycss-morph test:coverage | |
| - name: Enforce domformat coverage | |
| run: pnpm --filter @layoutit/polycss-domformat test:coverage | |
| - name: Certify domformat package | |
| run: pnpm --filter @layoutit/polycss-domformat pack:check | |
| - name: Build packages (DTS + JS) | |
| run: pnpm build:packages | |
| - name: Certify Morph package | |
| run: pnpm --filter @layoutit/polycss-morph test:package | |
| - name: Certify Morph with registry dependencies | |
| run: pnpm --filter @layoutit/polycss-morph test:package:registry | |
| - name: Certify Gallery domformat corpus | |
| run: pnpm --filter @layoutit/polycss-website test:domformat-tools && pnpm --filter @layoutit/polycss-website verify:domformat | |
| - name: Build website | |
| run: pnpm build:website | |
| certify-domformat-browser-and-corpus: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 45 | |
| steps: | |
| - name: Check out | |
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 | |
| - name: Set up pnpm | |
| uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda | |
| with: | |
| version: 10.32.1 | |
| - name: Set up Node | |
| uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 | |
| with: | |
| node-version: 22 | |
| cache: pnpm | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Install pinned Playwright Chromium | |
| run: pnpm exec playwright install --with-deps chromium | |
| - name: Expose pinned Playwright Chromium executable | |
| run: >- | |
| node --input-type=module --eval 'import { chromium } from "playwright"; process.stdout.write("DOMFORMAT_BROWSER=" + chromium.executablePath() + "\n");' >> "$GITHUB_ENV" | |
| - name: Certify domformat in real Chromium | |
| env: | |
| DOMFORMAT_BROWSER_NO_SANDBOX: "1" | |
| run: pnpm --filter @layoutit/polycss-domformat test:browser | |
| - name: Regenerate and compare the complete Gallery corpus | |
| run: pnpm --filter @layoutit/polycss-website verify:domformat:fresh |