Skip to content

Commit 0cb3615

Browse files
Copilotserhalp
andauthored
ci: split test CI workflow into separate workflows for lint, typecheck, unit test, build (#77)
* Initial plan for issue * Split test workflow into separate lint, typecheck, unit-test, and build workflows Co-authored-by: serhalp <[email protected]> * Add explicit permissions to all workflow files to resolve CodeQL warning Co-authored-by: serhalp <[email protected]> * fix: update workflow triggers to run on push to main and all PRs Co-authored-by: serhalp <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: serhalp <[email protected]> Co-authored-by: Philippe Serhal <[email protected]>
1 parent f54d66d commit 0cb3615

File tree

4 files changed

+85
-7
lines changed

4 files changed

+85
-7
lines changed
Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
1-
name: All Tests
1+
name: Build
22

3-
on: [push, pull_request]
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
permissions:
9+
contents: read
410

511
jobs:
6-
test:
12+
build:
713
runs-on: ubuntu-latest
814

915
steps:
@@ -16,7 +22,4 @@ jobs:
1622
run: corepack enable
1723
- run: pnpm install
1824

19-
- run: pnpm run lint
20-
- run: pnpm run typecheck
21-
- run: pnpm run test:unit
22-
- run: pnpm run build
25+
- run: pnpm run build

.github/workflows/lint.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Lint
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
lint:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v4
17+
- name: Set up Node.js
18+
uses: actions/setup-node@v4
19+
with:
20+
node-version: 22.x
21+
- name: Set up PNPM
22+
run: corepack enable
23+
- run: pnpm install
24+
25+
- run: pnpm run lint

.github/workflows/typecheck.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Type Check
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
typecheck:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v4
17+
- name: Set up Node.js
18+
uses: actions/setup-node@v4
19+
with:
20+
node-version: 22.x
21+
- name: Set up PNPM
22+
run: corepack enable
23+
- run: pnpm install
24+
25+
- run: pnpm run typecheck

.github/workflows/unit-test.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Unit Tests
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
unit-test:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v4
17+
- name: Set up Node.js
18+
uses: actions/setup-node@v4
19+
with:
20+
node-version: 22.x
21+
- name: Set up PNPM
22+
run: corepack enable
23+
- run: pnpm install
24+
25+
- run: pnpm run test:unit

0 commit comments

Comments
 (0)