Skip to content

Commit f912c32

Browse files
unamedkrclaude
andcommitted
test: chain test_tokenizer.sh at the tail of test_models.sh
Running 'bash scripts/test_models.sh' now also exercises the BPE stale-entry + UTF-8 direct-byte regression fixtures (v0.27.0 invariants) without a separate command. Combined output: 15 coherence PASS + 8 tokenizer PASS = 23/23 in one run. Exit code is 1 if either sub-suite fails; TOK_SCRIPT discovered via sibling path so no build-system coupling. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent dc4152d commit f912c32

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

scripts/test_models.sh

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,19 @@ echo " PASS: $PASS"
130130
echo " FAIL: $FAIL"
131131
echo " SKIP: $SKIP"
132132

133-
if [[ "$FAIL" -gt 0 ]]; then
133+
# Chain the tokenizer-level regression so 'the' regression is one command.
134+
# BPE stale-entry + UTF-8 direct-byte (v0.27.0) are invariants we must never
135+
# regress — running them here makes that guarantee automatic.
136+
TOK_SCRIPT="$(dirname "$0")/test_tokenizer.sh"
137+
if [[ -x "$TOK_SCRIPT" || -f "$TOK_SCRIPT" ]]; then
138+
echo ""
139+
BIN="$QUANT_BIN" MODELS_DIR="$MODELS_DIR" bash "$TOK_SCRIPT"
140+
TOK_RC=$?
141+
else
142+
TOK_RC=0
143+
fi
144+
145+
if [[ "$FAIL" -gt 0 || "$TOK_RC" -ne 0 ]]; then
134146
exit 1
135147
fi
136148
exit 0

0 commit comments

Comments
 (0)