-
Notifications
You must be signed in to change notification settings - Fork 1
40 lines (35 loc) · 1010 Bytes
/
Copy pathci.yml
File metadata and controls
40 lines (35 loc) · 1010 Bytes
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
name: CI
on:
pull_request:
branches: [main]
push:
branches: [main]
paths:
- 'src/**'
- 'action.yml'
- '.github/workflows/ci.yml'
permissions:
contents: read
jobs:
smoke:
name: Smoke test (renders all themes)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: '22'
- name: Render every theme and validate output
env:
THM_USERNAME: Keizer
THM_FIXTURE: src/__fixtures__/profile.json
run: |
set -euo pipefail
for theme in midnight matrix synthwave inferno frost rotate random; do
echo "::group::theme=$theme"
THEME="$theme" OUTPUT_PATH="/tmp/badge-$theme.svg" node src/generate.js
test -s "/tmp/badge-$theme.svg"
head -c 5 "/tmp/badge-$theme.svg" | grep -q '<svg'
echo "::endgroup::"
done
echo "All themes rendered successfully."