chore: scaffold tracks and tooling

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Lucas Winther
2026-10-28 23:34:21 +01:00
co-authored by Claude Opus 5.5
parent 6dc5bdde9e
commit e150b7fefb
27 changed files with 282 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
#!/usr/bin/env bash
# Usage: scripts/check-stubs.sh <js|scala|fsharp>
# Runs each module M01..M11 that has tests against the stubs in src/. Fails if any module's tests pass.
set -uo pipefail
track="${1:?usage: check-stubs.sh <js|scala|fsharp>}"
repo="$(cd "$(dirname "$0")/.." && pwd)"
dir="$repo/$track"
case "$track" in
js) has() { compgen -G "$dir/test/m$1-*.test.js" >/dev/null; } ;;
scala) has() { compgen -G "$dir/test/M$1*.test.scala" >/dev/null; } ;;
fsharp) has() { compgen -G "$dir/tests/M$1*.fs" >/dev/null; } ;;
*) echo "unknown track: $track" >&2; exit 2 ;;
esac
status=0
for n in 01 02 03 04 05 06 07 08 09 10 11; do
m="M$n"
if ! has "$n"; then echo "$m: no tests"; continue; fi
if (cd "$dir" && ./test.sh "$m") >/dev/null 2>&1; then
echo "$m: FAIL (tests pass against stubs)"; status=1
else
echo "$m: ok (fails against stubs)"
fi
done
exit $status