File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6969 zig-build-release :
7070 name : zig build release
7171
72- # Don't run the CI on PR
73- if : github.event_name != 'pull_request'
74-
7572 runs-on : ubuntu-latest
7673
7774 steps :
8683 - name : zig build release
8784 run : zig build -Doptimize=ReleaseSafe -Dengine=v8
8885
86+ - name : upload artifact
87+ uses : actions/upload-artifact@v4
88+ with :
89+ name : lightpanda-build-release
90+ path : |
91+ zig-out/bin/lightpanda
92+ retention-days : 1
93+
8994 zig-test :
9095 name : zig test
9196
@@ -146,6 +151,10 @@ jobs:
146151 name : demo-puppeteer
147152 needs : zig-build-dev
148153
154+ env :
155+ MAX_MEMORY : 23456
156+ MAX_AVG_DURATION : 22
157+
149158 runs-on : ubuntu-latest
150159
151160 steps :
@@ -159,12 +168,21 @@ jobs:
159168 - name : download artifact
160169 uses : actions/download-artifact@v4
161170 with :
162- name : lightpanda-build-dev
171+ name : lightpanda-build-release
163172
164173 - run : chmod a+x ./lightpanda
165174
166175 - name : run puppeteer
167176 run : |
168- python3 -m http.server 1234 -d ./public &
169- ./lightpanda &
170- RUNS=2 npm run bench-puppeteer-cdp
177+ go run ws/main.go &
178+ /usr/bin/time -f'%M' -omrs.out ./lightpanda &
179+ RUNS=100 npm run bench-puppeteer-cdp |tee output
180+
181+ - name : memory regression
182+ run : |
183+ test "`cat mrs.out`" -le "$MAX_MEMORY"
184+
185+ - name : duration regression
186+ run : |
187+ test "`cat output|grep 'avg run'|sed 's/avg run duration (ms) //'`" -le "$MAX_AVG_DURATION"
188+
You can’t perform that action at this time.
0 commit comments