mirror of
https://github.com/saphid/frame-control.git
synced 2026-10-06 00:00:21 +02:00
Flatpak installs record their outcome inside main's background job; failed jobs are diagnostics too. The Privacy panel lives on the Tools page (#privacy opens it), tab analytics use the four page names, and "Test it now?" reads the install job's result. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
90 lines
3.3 KiB
YAML
90 lines
3.3 KiB
YAML
name: checks
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
jobs:
|
|
checks:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-python@v5
|
|
with:
|
|
python-version: "3.9" # the oldest python3 the Mac app may pick up (Xcode CLT)
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: "24"
|
|
- name: Install zsh
|
|
run: sudo apt-get update -qq && sudo apt-get install -y -qq zsh
|
|
- name: Script syntax
|
|
run: |
|
|
sh -n ui/local-bin/ssh
|
|
for f in scripts/*.sh frame/*/*.sh; do
|
|
case "$(head -n 1 "$f")" in
|
|
*zsh*) zsh -n "$f" ;;
|
|
*) bash -n "$f" ;;
|
|
esac
|
|
done
|
|
- name: Python compiles
|
|
run: |
|
|
python -m py_compile ui/*.py apk-catalog/*.py frame/android/*.py ios/scripts/*.py
|
|
# Valve's devkit-utils (vendored; run by the Frame's python3). Most have no .py suffix.
|
|
python -m py_compile $(find frame/devkit-utils -type f ! -name '*.*' ! -name LICENSE) frame/devkit-utils/devkit_utils/*.py
|
|
- name: Server tests
|
|
run: python -m unittest discover -s tests -v
|
|
- name: App syntax
|
|
run: node --check app/main.js && node --check app/build/make-icon.js && node --check app/build/fetch-deps.js && node --check app/preload.js && node --check app/install-link.js && node --check app/updater.js
|
|
- name: Updater tests
|
|
run: node --test app/test/updater.test.js
|
|
- name: Website
|
|
run: node --test site/test/*.test.mjs && node --check site/public/js/site.js && node --check site/public/js/feedback.js
|
|
|
|
# The server runs on each desktop OS the app ships for, on the Python version
|
|
# the app bundles (app/build/fetch-deps.js) and, on Ubuntu, a newer one.
|
|
server-tests:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
include:
|
|
- os: windows-latest
|
|
python: "3.12"
|
|
- os: macos-latest
|
|
python: "3.12"
|
|
- os: ubuntu-latest
|
|
python: "3.13"
|
|
runs-on: ${{ matrix.os }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-python@v5
|
|
with:
|
|
python-version: ${{ matrix.python }}
|
|
- name: Server tests
|
|
run: python -m unittest discover -s tests -v
|
|
|
|
# The iPhone app: builds for the Simulator and runs its unit tests.
|
|
ios:
|
|
runs-on: macos-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Generate the project
|
|
run: brew install xcodegen && cd ios && xcodegen generate
|
|
- name: Build and test
|
|
run: |
|
|
cd ios
|
|
udid=$(xcrun simctl list devices available -j | python3 -c 'import json,sys; d=json.load(sys.stdin)["devices"]; print(next(x["udid"] for r in d for x in d[r] if x["name"].startswith("iPhone")))')
|
|
xcodebuild -project FrameControl.xcodeproj -scheme FrameControl -destination "platform=iOS Simulator,id=$udid" CODE_SIGNING_ALLOWED=NO test
|
|
|
|
# End-to-end tests against the fake Frame (tests/fakeframe): Arch Linux ARM
|
|
# in Docker, on a native arm64 runner like the headset. See docs/testing.md.
|
|
e2e:
|
|
runs-on: ubuntu-24.04-arm
|
|
timeout-minutes: 30
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Install zsh
|
|
run: sudo apt-get update -qq && sudo apt-get install -y -qq zsh
|
|
- name: End-to-end tests
|
|
run: scripts/e2e.sh
|