`ci/test.sh` now runs `flutter test --coverage`, so `ci/test_coverage.sh` was just re-running the same tests plus an optional `lcov --summary` that needs `lcov` installed (it wasn't, on at least this machine). Removing it. - ci/test_coverage.sh: deleted. - Makefile: drop the `coverage` target (it only wrapped the dead script). Fix a stale `coverage/floor.txt` reference in the `coverage-gate` help text — the floor lives in pubspec.yaml now. - .gitea/workflows/test.yml: replace the test_coverage.sh invocation with ci/coverage_gate.sh, so CI enforces the same floor as the pre-push hook (defense in depth). Co-Authored-By: Claude <noreply@anthropic.com>
93 lines
2.8 KiB
YAML
93 lines
2.8 KiB
YAML
# Gitea Actions workflow for clide.
|
|
#
|
|
# NOT YET ACTIVATED. Gitea Actions must be enabled in the instance
|
|
# settings before this runs; until then the file is just a ready-made
|
|
# pipeline Claude + the user can review.
|
|
#
|
|
# When the repo eventually lands on GitHub, copy this file verbatim to
|
|
# `.github/workflows/test.yml` — Gitea Actions consumes GitHub-Actions
|
|
# syntax, so no rewrite is needed.
|
|
|
|
name: test
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
jobs:
|
|
unit:
|
|
name: unit + widget + golden + a11y
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: subosito/flutter-action@v2
|
|
with: { channel: stable, cache: true }
|
|
- run: dart pub get
|
|
- run: (cd app && flutter pub get)
|
|
- run: ci/test.sh
|
|
- run: ci/test_a11y.sh
|
|
- run: ci/coverage_gate.sh
|
|
|
|
integration:
|
|
name: integration_test (xvfb)
|
|
runs-on: ubuntu-latest
|
|
needs: unit
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: subosito/flutter-action@v2
|
|
with: { channel: stable, cache: true }
|
|
- run: sudo apt-get update && sudo apt-get install -y xvfb ninja-build libgtk-3-dev
|
|
- run: dart pub get
|
|
- run: (cd app && flutter pub get)
|
|
- uses: coactions/setup-xvfb@v1
|
|
with: { run: ci/test_integration.sh }
|
|
|
|
startup-bundle:
|
|
name: bundle smoke (xvfb 5s)
|
|
runs-on: ubuntu-latest
|
|
needs: unit
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: subosito/flutter-action@v2
|
|
with: { channel: stable, cache: true }
|
|
- run: sudo apt-get update && sudo apt-get install -y xvfb ninja-build libgtk-3-dev
|
|
- run: dart pub get
|
|
- run: (cd app && flutter pub get)
|
|
- run: ci/smoke_bundle.sh
|
|
|
|
e2e:
|
|
name: daemon subprocess + web WASM smoke
|
|
runs-on: ubuntu-latest
|
|
needs: unit
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: subosito/flutter-action@v2
|
|
with: { channel: stable, cache: true }
|
|
- uses: actions/setup-node@v4
|
|
with: { node-version: 20 }
|
|
- run: dart pub get
|
|
- run: (cd app && flutter pub get)
|
|
- run: (cd tools/ui && npm install && npx playwright install --with-deps chromium)
|
|
- run: ci/test_e2e.sh
|
|
|
|
docs:
|
|
name: dart doc (lib API)
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: subosito/flutter-action@v2
|
|
with: { channel: stable, cache: true }
|
|
- run: dart pub get
|
|
- name: dart doc --validate-links (fail on warning)
|
|
run: |
|
|
set -o pipefail
|
|
dart doc --validate-links 2>&1 | tee dartdoc.log
|
|
if grep -q "^ warning:" dartdoc.log; then
|
|
echo "::error::dartdoc emitted warnings — see log above"
|
|
exit 1
|
|
fi
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: dart-api-docs
|
|
path: doc/api/
|