-
Notifications
You must be signed in to change notification settings - Fork 0
120 lines (113 loc) · 4.45 KB
/
Copy pathci.yml
File metadata and controls
120 lines (113 loc) · 4.45 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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
test-ubuntu-x64-gnu:
name: Build and test Ubuntu x64
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v7
- uses: pnpm/setup@v2
with:
version: 11.20.0
runtime: node@22.20.0
cache: true
install: false
- uses: dtolnay/rust-toolchain@stable
- run: pnpm install --frozen-lockfile
- name: Build and run all tests
run: pnpm exec vp run check:test
- name: Smoke test @taffyjs/node with Bun 1.2
run: pnpm dlx bun@1.2.0 packages/taffyjs-node/tests/runtime-smoke.mjs
- name: Smoke test @taffyjs/node with Deno 2.2
run: pnpm dlx deno@2.2.0 run --node-modules-dir=manual --allow-env --allow-read --allow-ffi packages/taffyjs-node/tests/runtime-smoke.mjs
- name: Smoke test @taffyjs/yoga with Bun 1.2
run: pnpm dlx bun@1.2.0 tests/taffyjs-yoga/runtime-smoke.mjs
- name: Smoke test @taffyjs/yoga with Deno 2.2
run: pnpm dlx deno@2.2.0 run --node-modules-dir=manual --allow-env --allow-read --allow-ffi tests/taffyjs-yoga/runtime-smoke.mjs
- name: Verify committed package outputs are current
run: git diff --exit-code -- packages/taffyjs-node/index.js packages/taffyjs-node/index.d.ts packages/taffyjs-node/binding.js packages/taffyjs-node/binding.d.ts
test-windows-x64-msvc:
name: Build and test Windows x64
runs-on: windows-2022
steps:
- uses: actions/checkout@v7
- uses: pnpm/setup@v2
with:
version: 11.20.0
runtime: node@22.20.0
cache: true
install: false
- uses: dtolnay/rust-toolchain@stable
- run: pnpm install --frozen-lockfile
- name: Build and run all tests
run: pnpm exec vp run check:test
- name: Smoke test @taffyjs/node with Bun 1.2
run: pnpm dlx bun@1.2.0 packages/taffyjs-node/tests/runtime-smoke.mjs
- name: Smoke test @taffyjs/node with Deno 2.2
run: pnpm dlx deno@2.2.0 run --node-modules-dir=manual --allow-env --allow-read --allow-ffi packages/taffyjs-node/tests/runtime-smoke.mjs
- name: Smoke test @taffyjs/yoga with Bun 1.2
run: pnpm dlx bun@1.2.0 tests/taffyjs-yoga/runtime-smoke.mjs
- name: Smoke test @taffyjs/yoga with Deno 2.2
run: pnpm dlx deno@2.2.0 run --node-modules-dir=manual --allow-env --allow-read --allow-ffi tests/taffyjs-yoga/runtime-smoke.mjs
test-wasm:
name: Build and test Wasm
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v7
- uses: pnpm/setup@v2
with:
version: 11.20.0
runtime: node@22.20.0
cache: true
install: false
- uses: dtolnay/rust-toolchain@stable
with:
targets: wasm32-wasip1
- run: pnpm install --frozen-lockfile
- name: Install the browser used by the Wasm runtime tests
run: pnpm --filter tests-taffy-wasm exec playwright install --with-deps chromium
- name: Build and test the Wasm packages
run: pnpm exec vp run check:wasm
- name: Smoke test @taffyjs/wasm with Bun 1.2
run: pnpm dlx bun@1.2.0 packages/taffyjs-wasm/tests/runtime-smoke.mjs
- name: Smoke test @taffyjs/wasm with Deno 2.2
run: pnpm dlx deno@2.2.0 run --node-modules-dir=manual packages/taffyjs-wasm/tests/runtime-smoke.mjs
check-node:
name: Node checks
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v7
- uses: pnpm/setup@v2
with:
version: 11.20.0
runtime: node@22.20.0
cache: true
install: false
- run: pnpm install --frozen-lockfile
- name: Check formatting
run: pnpm exec vp run check:format
- name: Check JavaScript and TypeScript
run: pnpm exec vp run check:lint
- name: Verify native platform metadata
run: pnpm exec vp run check:platforms
- name: Verify release configuration
run: pnpm exec vp run check:release
- name: Verify generated sources are committed
run: pnpm exec vp run check:codegen
check-rust:
name: Rust checks
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v7
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
- name: Check formatting
run: cargo fmt --all -- --check
- name: Run Clippy
run: cargo clippy --workspace --all-targets --all-features --locked -- -D warnings