-
Notifications
You must be signed in to change notification settings - Fork 1
83 lines (78 loc) · 2.39 KB
/
Copy pathci.yml
File metadata and controls
83 lines (78 loc) · 2.39 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
name: CI
on:
push:
branches: [main, trunk]
pull_request:
branches: [main]
jobs:
build-lint-test:
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
node-version: [20, 22]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Install tmux (macOS)
if: runner.os == 'macOS'
run: brew install tmux
- run: npm ci
- run: npx tsc --build
- run: npx eslint .
- name: Unit tests
run: npm test
- name: E2E tests (sessions)
run: npx tsx --test 'packages/cli/test/e2e/sessions.e2e.ts'
- name: Install opencode
run: npm install -g opencode-ai
- name: E2E tests (opencode)
run: npx tsx --test 'packages/cli/test/e2e/opencode.e2e.ts'
e2e-docker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- run: npm ci
- run: npx tsc --build
- name: E2E tests (sandbox with Docker)
run: npx tsx --test 'packages/cli/test/e2e/sandbox-engines.e2e.ts'
e2e-podman:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- name: Install Podman
run: sudo apt-get update && sudo apt-get install -y podman
- run: npm ci
- run: npx tsc --build
- name: E2E tests (sandbox with Podman)
run: npx tsx --test 'packages/cli/test/e2e/sandbox-engines.e2e.ts'
e2e-colima:
runs-on: macos-latest
# Colima needs nested virtualization which macOS CI runners don't reliably support.
continue-on-error: true
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- name: Install Colima
run: brew install colima docker
- name: Start Colima
run: colima start --runtime docker || echo "Colima VM failed to start (expected on some CI runners)"
- run: npm ci
- run: npx tsc --build
- name: E2E tests (sandbox with Colima)
run: |
if colima status 2>/dev/null; then
npx tsx --test 'packages/cli/test/e2e/sandbox-engines.e2e.ts'
else
echo "Skipping: Colima is not running"
fi