-
Notifications
You must be signed in to change notification settings - Fork 5
77 lines (60 loc) · 2.78 KB
/
Copy pathci.yml
File metadata and controls
77 lines (60 loc) · 2.78 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
name: ci
on:
pull_request:
branches:
- dev
- master
jobs:
ci:
strategy:
matrix:
os: [ubuntu-24.04]
node: [24.x]
name: Continuous Integration (${{ matrix.os }} / Node.js ${{ matrix.node }})
runs-on: ${{ matrix.os }}
steps:
- name: ☁️ Checkout repository
uses: actions/checkout@v7
with:
fetch-depth: 0
- name: 🟩 Setup Node.js ${{ matrix.node }}
uses: ./.github/actions/node-setup
with:
node-version: ${{ matrix.node }}
- name: 🔍 Run linter
run: pnpm lint
- name: 🧪 Run core tests
run: pnpm --filter @kelvininc/ui-components test
- name: 🏗️ Build all packages
run: pnpm build:packages
- name: 🧪 Run React tests
run: pnpm --filter @kelvininc/react-ui-components test
- name: 💅 Build storybook
run: pnpm storybook:build
summary:
name: CI Summary
runs-on: ubuntu-24.04
needs: [ci]
if: always()
steps:
- name: Generate workflow summary
run: |
cat >> $GITHUB_STEP_SUMMARY << 'EOF'
# Kelvin UI Components - Pull Request Summary
## Build Information
- **Commit**: `${{ github.sha }}`
- **Branch**: `${{ github.head_ref }}`
- **Target**: `${{ github.base_ref }}`
- **Environment**: Pull Request
## Component Status
| Component | Status |
|-----------|---------|
| CI (Lint + Test + Build + Storybook) | ${{ needs.ci.result == 'success' && '✅ Success' || needs.ci.result == 'skipped' && '⏭️ Skipped' || '❌ Failed' }} |
## Testing Summary
- **Linting**: ${{ needs.ci.result == 'success' && '✅ Passed' || needs.ci.result == 'skipped' && '⏭️ Skipped' || '❌ Failed' }}
- **Unit Tests**: ${{ needs.ci.result == 'success' && '✅ Passed' || needs.ci.result == 'skipped' && '⏭️ Skipped' || '❌ Failed' }}
- **Package Build**: ${{ needs.ci.result == 'success' && '✅ Passed' || needs.ci.result == 'skipped' && '⏭️ Skipped' || '❌ Failed' }}
- **Storybook Build**: ${{ needs.ci.result == 'success' && '✅ Passed' || needs.ci.result == 'skipped' && '⏭️ Skipped' || '❌ Failed' }}
---
> **Next Steps**: Once this PR is approved and merged, it will trigger the appropriate deployment workflow based on the target branch.
EOF