From ae546d5bd210bbc5934f9daec5acd9be791acf42 Mon Sep 17 00:00:00 2001 From: Thomas Date: Tue, 29 Sep 2026 18:03:28 -0400 Subject: [PATCH] Run frontend tests on Windows and diagnose startup timeouts - Run the Python 3.13 frontend suite on Windows CI - Include captured page errors in smoke-test startup failures and document coverage --- .github/workflows/tests.yml | 10 ++++----- docs/tests.md | 4 ++-- tests/frontend/flag_sync_smoke.cjs | 36 +++++++++++++++++++++++++++--- 3 files changed, 40 insertions(+), 10 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 1d6be02a..c4945813 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -50,18 +50,18 @@ jobs: run: python -m unittest discover tests -v - name: Set up Node for frontend smoke test - if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.13' + if: matrix.python-version == '3.13' uses: actions/setup-node@v4 with: node-version: "22" cache: npm - name: Install frontend test dependencies - if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.13' + if: matrix.python-version == '3.13' run: npm ci - name: Install Playwright Chromium - if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.13' + if: matrix.python-version == '3.13' run: npx playwright install chromium - name: Prepare pinned llama.cpp CPU binaries @@ -99,6 +99,6 @@ jobs: print(f'Prepared llama.cpp {pin["tag"]}: {pin["asset"]}') PY - - name: Run frontend tests with required flag compatibility - if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.13' + - name: Run frontend tests + if: matrix.python-version == '3.13' run: npm test diff --git a/docs/tests.md b/docs/tests.md index 10e7a070..c212e59d 100644 --- a/docs/tests.md +++ b/docs/tests.md @@ -58,7 +58,7 @@ node tests/frontend/llama_flags_supported_unit.cjs --require-binaries An explicit `LLAMA_GUI_LLAMA_BIN_DIR` (or legacy `LLAMA_CPP_BIN_DIR`) requires both executables and disables fallback to other installations. Missing binaries, failed/timed-out `--help`, and unsupported flags fail the check. `--require-binaries` also requires an explicit directory. This checks advertised flag names, including negated booleans; it does not validate enum values or GPU execution. Fork-only flags are excluded. -The Ubuntu/Python 3.13 CI job installs the `libgomp1` OpenMP runtime, downloads the exact CPU release in `tests/llama-cpp-pin.json`, verifies its SHA256, and sets the explicit directory before `npm test`. Update the tag, asset, and checksum together from an official llama.cpp release, then run compatibility before accepting the new pin. No model or GPU is needed. +The Ubuntu and Windows/Python 3.13 CI jobs run `npm test`, including the unit and browser suites. The Ubuntu job also installs the `libgomp1` OpenMP runtime, downloads the exact CPU release in `tests/llama-cpp-pin.json`, verifies its SHA256, and sets the explicit directory for required binary compatibility. The Windows job uses the same optional binary check as the release workflow. Update the tag, asset, and checksum together from an official llama.cpp release, then run compatibility before accepting the new pin. No model or GPU is needed. ```powershell npm run test:frontend @@ -66,7 +66,7 @@ npm run test:frontend Runs the Playwright smoke test for browser-level shared-state sync. This is also the only suite that can cover the Configure sampler preset panel, because `renderFlags()` destroys and rebuilds it — the `