Skip to content
This repository was archived by the owner on May 6, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 31 additions & 12 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,44 @@ name: Build

on: [push]

env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

jobs:
build:
name: build (v22.15.1)
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [v22.15.1]

steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v6
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v6
- uses: actions/setup-node@v6
with:
node-version: v22.15.1
cache: pnpm
- name: Cache node_modules
id: modules-cache
uses: actions/cache@v4
with:
path: node_modules
key: node-modules-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}
- name: Install
if: steps.modules-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
env:
CI: true
- name: Typecheck
run: pnpm typecheck
env:
CI: true
- name: Cache dist
id: dist-cache
uses: actions/cache@v4
with:
node-version: ${{ matrix.node-version }}
- name: Install and build
run: |
pnpm install --frozen-lockfile
pnpm typecheck
pnpm build
path: build
key: dist-${{ runner.os }}-${{ hashFiles('src/**', 'public/**', 'index.html', 'vite.config.*', 'tsconfig*', 'pnpm-lock.yaml') }}
- name: Build
if: steps.dist-cache.outputs.cache-hit != 'true'
run: pnpm build
env:
CI: true
29 changes: 19 additions & 10 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,33 @@ name: Lint server

on: [push]

env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

jobs:
build:
name: build (v22.15.1)
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [v22.15.1]

steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v6
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v6
- uses: actions/setup-node@v6
with:
node-version: v22.15.1
cache: pnpm
- name: Cache node_modules
id: modules-cache
uses: actions/cache@v4
with:
node-version: ${{ matrix.node-version }}
path: node_modules
key: node-modules-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}
- name: Install
if: steps.modules-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
env:
CI: true
- name: Run lint
run: |
pnpm install --frozen-lockfile
pnpm lint
run: pnpm lint
env:
CI: true
31 changes: 28 additions & 3 deletions .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,46 @@ on:
branches: [main]
pull_request:
branches: [main]
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

jobs:
test:
timeout-minutes: 60
timeout-minutes: 15
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v6
- uses: actions/setup-node@v6
with:
node-version: v22.15.1
- uses: pnpm/action-setup@v6
cache: pnpm
- name: Cache node_modules
id: modules-cache
uses: actions/cache@v4
with:
path: node_modules
key: node-modules-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}
- name: Install dependencies
if: steps.modules-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
- name: Cache Playwright browsers
uses: actions/cache@v4
id: playwright-cache
with:
path: ~/.cache/ms-playwright
key: playwright-${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }}
- name: Install Playwright Browsers
run: pnpm exec playwright install --with-deps
if: steps.playwright-cache.outputs.cache-hit != 'true'
run: pnpm exec playwright install --with-deps chromium
- name: Cache dist
id: dist-cache
uses: actions/cache@v4
with:
path: build
key: dist-${{ runner.os }}-${{ hashFiles('src/**', 'public/**', 'index.html', 'vite.config.*', 'tsconfig*', 'pnpm-lock.yaml') }}
- name: Build the application
if: steps.dist-cache.outputs.cache-hit != 'true'
run: pnpm build
- name: Run Playwright tests
run: pnpm exec playwright test
Expand Down
31 changes: 20 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,33 @@ name: test

on: [push]

env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

jobs:
build:
name: build (v22.15.1)
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [v22.15.1]

steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v6
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v6
- uses: actions/setup-node@v6
with:
node-version: v22.15.1
cache: pnpm
- name: Cache node_modules
id: modules-cache
uses: actions/cache@v4
with:
node-version: ${{ matrix.node-version }}
- name: Web
run: |
pnpm install --frozen-lockfile
pnpm test
path: node_modules
key: node-modules-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}
- name: Install
if: steps.modules-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
env:
CI: true
- name: Test
run: pnpm test
env:
CI: true
18 changes: 4 additions & 14 deletions playwright.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { defineConfig, devices } from '@playwright/test';

// Check if we need to run the mock server based on environment variable or test patterns
const shouldRunMockServer =
process.env.PLAYWRIGHT_WITH_MOCK === 'true' ||
process.argv.some((arg) => arg.includes('mock-api.spec.ts'));
Expand All @@ -9,8 +8,8 @@ export default defineConfig({
testDir: './tests',
fullyParallel: true,
forbidOnly: !!process.env.CI,
retries: process.env.CI ? 2 : 0,
workers: process.env.CI ? 1 : undefined,
retries: process.env.CI ? 1 : 0,
workers: '100%',
reporter: 'html',
use: {
baseURL: process.env.CI ? 'http://localhost:4173' : 'http://localhost:3000',
Expand All @@ -22,16 +21,7 @@ export default defineConfig({
name: 'chromium',
use: { ...devices['Desktop Chrome'] },
},
{
name: 'firefox',
use: { ...devices['Desktop Firefox'] },
},
{
name: 'webkit',
use: { ...devices['Desktop Safari'] },
},
],
// Conditionally start mock server based on test needs
webServer: shouldRunMockServer
? [
{
Expand All @@ -41,7 +31,7 @@ export default defineConfig({
timeout: 120 * 1000,
},
{
command: process.env.CI ? 'npm run preview' : 'npm run start',
command: process.env.CI ? 'pnpm run preview' : 'pnpm run start',
url: process.env.CI
? 'http://localhost:4173'
: 'http://localhost:3000',
Expand All @@ -50,7 +40,7 @@ export default defineConfig({
},
]
: {
command: process.env.CI ? 'npm run preview' : 'npm run start',
command: process.env.CI ? 'pnpm run preview' : 'pnpm run start',
url: process.env.CI ? 'http://localhost:4173' : 'http://localhost:3000',
reuseExistingServer: !process.env.CI,
timeout: 120 * 1000,
Expand Down
Loading