Read the sources from disk instead of a hand-maintained allow-list that the script uses destructively, and add a guard that fails when the project and directory disagree. FlutterNativeTextInputTests.mm was the second test the list would have silently unwired.
32 lines
1.1 KiB
Bash
32 lines
1.1 KiB
Bash
#!/usr/bin/env bash
|
|
# Workflow and script regression guards.
|
|
#
|
|
# Single source of truth for the guard roster, shared by the "Verify workflow
|
|
# and script guards" step in .github/workflows/ci.yml and section 4 of
|
|
# scripts/ci_checks.sh. The checkers are named explicitly because a few of them
|
|
# belong to other jobs (check_bun_audit.py needs Bun, check_codegen.py runs via
|
|
# codegen.sh), but their regression tests are discovered by glob so a newly
|
|
# added scripts/test_*.py is picked up automatically instead of having to be
|
|
# remembered in two places.
|
|
set -euo pipefail
|
|
shopt -s nullglob
|
|
|
|
ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
|
cd "$ROOT_DIR"
|
|
|
|
for checker in \
|
|
scripts/check_build_workflow.py \
|
|
scripts/check_apple_spm_locks.py \
|
|
scripts/check_tvos_test_wiring.py \
|
|
scripts/verify_runtime_inputs.py \
|
|
scripts/check_workflow_security.py \
|
|
scripts/check_workflow_action_pins.py \
|
|
scripts/check_container_image_pins.py \
|
|
scripts/check_update_packages_workflow.py; do
|
|
python3 "$checker"
|
|
done
|
|
|
|
for guard_test in scripts/test_*.py; do
|
|
python3 "$guard_test"
|
|
done
|