Skip to content

feat: 툴바에 지금 보고 있는 워크트리와 브랜치를 표시한다 #164

feat: 툴바에 지금 보고 있는 워크트리와 브랜치를 표시한다

feat: 툴바에 지금 보고 있는 워크트리와 브랜치를 표시한다 #164

Workflow file for this run

name: PR Check
on:
pull_request:
branches: [main]
# 연속 푸시가 중복 실행을 쌓지 않게 한다 — e2e가 붙은 뒤로 한 번 돌 때마다
# 브라우저 작업이 수 분씩 들어간다.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: oven-sh/setup-bun@v2
- run: bun install --frozen-lockfile
- name: Lint (oxlint)
run: bun run lint
- name: Check formatting (oxfmt)
run: bun run format:check
typecheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: oven-sh/setup-bun@v2
- run: bun install --frozen-lockfile
- run: bun run typecheck
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: oven-sh/setup-bun@v2
- run: bun install --frozen-lockfile
- run: bun test
coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: oven-sh/setup-bun@v2
- run: bun install --frozen-lockfile
- name: 100% coverage gate (owned runtime code)
run: bun run test:coverage
# e2e는 "실제로 보이는 것"을 검증하는 유일한 레인이다 — happy-dom에는
# 레이아웃이 없어서 창 크기가 변하지 않는지·버튼이 실제로 페인트되는지·
# 클릭해도 포커스가 남는지는 유닛이 원리적으로 못 잡는다. 게이트에 없으면
# 그 계약들은 아무도 지키지 않는다. 다른 잡보다 수십 배 무겁지만,
# 어느 계약이 깨질지 미리 알 수 없으므로 골라 돌리지 않고 전부 돌린다.
e2e:
runs-on: ubuntu-latest
# globalSetup(build.ts 실행)과 fixtures의 readUrlFromStdout에는 자체 타이머가
# 없고 Playwright의 per-test timeout도 그 둘을 덮지 않는다. 잡 타임아웃이
# 없으면 GHA 기본값이 6시간이라, 한 번 매달리면 러너를 그만큼 태운다
# (이 리포엔 실제로 Bun $ never-settle 행업 전례가 있다). 실제 소요는 수 분대라
# 15분은 넉넉한 상한이다 — 정확한 값은 최근 Actions 런이 답한다.
timeout-minutes: 15
steps:
- uses: actions/checkout@v7
- uses: oven-sh/setup-bun@v2
# Playwright Test는 spec·fixture·globalSetup을 항상 Node로 실행한다
# (bunx로 띄워도 마찬가지) — 러너 기본 Node에 기대지 않고 고정한다.
- uses: actions/setup-node@v7
with:
node-version: '24'
- run: bun install --frozen-lockfile
# playwright.config.ts가 channel:"chrome"이라 번들 Chromium이 아니라
# 실제 Google Chrome이 필요하다. --with-deps로 헤드리스 구동에 필요한
# 시스템 라이브러리까지 함께 깐다.
- name: Install Google Chrome for Playwright
run: bunx playwright install --with-deps chrome
# globalSetup이 build.ts를 1회 실행해 진짜 dist/cli.js를 만들고,
# 각 spec은 그걸 실제로 spawn한다.
- name: e2e (real browser)
run: bun run test:e2e
# 실패 산출물이 없으면 CI 전용 실패를 로컬에서 재현할 단서가 없다.
- name: Upload failure artifacts
if: failure()
uses: actions/upload-artifact@v7
with:
name: playwright-results
path: apps/viewer/test-results/
retention-days: 7