Files
baji-vc/scripts/check-emotion-regressions.sh

19 lines
1.2 KiB
Bash
Executable File

#!/bin/bash
# Model-free local JVM/rule/parser regressions; persistent numeric result for release checks.
set -euo pipefail
cd "$(dirname "$0")/.."
mkdir -p logs/voice-investigation
python3 scripts/check-reply-regressions.py > logs/voice-investigation/client-emotion-tests.txt 2>&1
./scripts/check-expression-rules.sh > logs/voice-investigation/expression-emotion-tests.txt 2>&1
(cd gateway && python3 -m unittest discover -s tests -p test_reply_emotion.py -v) > logs/voice-investigation/parser-emotion-tests.txt 2>&1
python3 - <<'PY'
import hashlib,json
from pathlib import Path
root=Path.cwd()
files=list((root/'app/src/main/java').rglob('*.kt')) + list((root/'tests').rglob('*.kt'))
files += [root/'gateway/reply_emotion.py',root/'scripts/check-reply-regressions.py']
result={'status':'passed','scope':'production Kotlin coordinator/playback/capture/protocol with device/transport doubles; pure face rules and structured parser','real_phone_playback':'not_tested','hashes':{str(p.relative_to(root)):hashlib.sha256(p.read_bytes()).hexdigest() for p in sorted(files)}}
(root/'logs/voice-investigation/client-emotion-tests.json').write_text(json.dumps(result,indent=2)+'\n')
print('Client/expression/parser emotion regressions passed (no real speaker)')
PY