|
38 | 38 | - name: pytest |
39 | 39 | run: uv run --locked pytest -q |
40 | 40 |
|
41 | | - - name: Install Lua |
42 | | - run: | |
43 | | - if [ "$RUNNER_OS" = "macOS" ]; then |
44 | | - brew install lua |
45 | | - else |
46 | | - sudo apt-get update && sudo apt-get install -y lua5.4 |
47 | | - sudo ln -sf "$(command -v lua5.4)" /usr/local/bin/lua |
48 | | - fi |
49 | | -
|
50 | | - # The client-side suite. It has never been wired into anything, so it |
51 | | - # only ran when someone remembered it existed. |
52 | | - - name: Lua client tests |
53 | | - run: lua tests/test_client_record.lua |
54 | 41 |
|
55 | 42 | shellcheck: |
56 | 43 | runs-on: ubuntu-latest |
|
60 | 47 | # Preinstalled on the Ubuntu runner image. |
61 | 48 | - name: shellcheck |
62 | 49 | run: shellcheck install-server.sh install-client.sh |
| 50 | + |
| 51 | + # The client is macOS-only and needs a real Swift toolchain, so it cannot |
| 52 | + # join the portable matrix above. Builds the bundle and asserts the signature |
| 53 | + # verifies — an unsigned or broken-signature bundle is exactly the state in |
| 54 | + # which TCC grants stop surviving a rebuild. |
| 55 | + swift: |
| 56 | + runs-on: macos-latest |
| 57 | + steps: |
| 58 | + - uses: actions/checkout@v7 |
| 59 | + |
| 60 | + - name: Test |
| 61 | + run: cd swift && swift test |
| 62 | + |
| 63 | + - name: Build Hark.app |
| 64 | + run: cd swift && swift build -c release && bash Packaging/build-app.sh |
| 65 | + |
| 66 | + - name: Verify the signature |
| 67 | + run: codesign --verify --strict --verbose=2 swift/Packaging/Hark.app |
| 68 | + |
| 69 | + - name: Verify the microphone entitlement survived signing |
| 70 | + run: | |
| 71 | + codesign -d --entitlements - --xml swift/Packaging/Hark.app 2>/dev/null \ |
| 72 | + | grep -q 'com.apple.security.device.audio-input' \ |
| 73 | + || { echo "missing audio-input entitlement — TCC will refuse to prompt"; exit 1; } |
0 commit comments