-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (28 loc) · 841 Bytes
/
Copy pathci.yml
File metadata and controls
31 lines (28 loc) · 841 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
name: Website checks
on:
pull_request:
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
jobs:
static-site:
name: Static site and design contract
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v5
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Verify Apple Design contract
run: python -m unittest discover -s tests -p 'test_*.py'
- name: Serve and smoke-test the published document
run: |
python -m http.server 8765 --directory . >/tmp/mhtoolkit-site.log 2>&1 &
server_pid=$!
trap 'kill "$server_pid"' EXIT
curl --fail --retry 5 --retry-connrefused http://127.0.0.1:8765/
- name: Reject whitespace errors
run: git diff --check