mirror of
https://github.com/hasso5703/alzeo.git
synced 2026-12-05 12:24:28 +01:00
tests: the OCR lane's engine port in the registry's check, its two ports in the suite's guard
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
9af94c4cbb
commit
3cee8d1d7d
2 files changed
+4
-2
No files matched your search
@@ -1452,7 +1452,7 @@ jobs:
|
||||
probe="$(mktemp -d)"
|
||||
# tests/run_suite.py loads the same hook into every python it starts (its sitecustomize.py),
|
||||
# beside the one that compares each file's environment at its start and at its exit.
|
||||
export QWEN38_CONTACT_LOG="$probe/contacts" QWEN38_SERVING_PORTS=30000,30001,30002,30020,30022,30024,30025,30026,30028,30030,30036,30090,30091,4096
|
||||
export QWEN38_CONTACT_LOG="$probe/contacts" QWEN38_SERVING_PORTS=30000,30001,30002,30020,30022,30024,30025,30026,30028,30030,30032,30034,30036,30090,30091,4096
|
||||
before="$(find "$witness" -type f -exec sha256sum {} + | sort)"
|
||||
ports_before="$(ss -Htln 2>/dev/null | awk '{print $4}' | sort || true)"
|
||||
# The suite runs under tests/suite_reaper.py, a child subreaper: every process it
|
||||
|
||||
@@ -1346,7 +1346,9 @@ class TheOtherScriptsSayTheSame(unittest.TestCase):
|
||||
m, where = one(rel, src, r'^PORT="\$\{[A-Z][A-Z0-9_]*_PORT:-\$\([a-z_]+ --port\)\}"; PORT="\$\{PORT:-(\d+)\}"$')
|
||||
p.same(f"{where} its PORT", [int(m.group(1))], f["ports"][:1])
|
||||
got, where = finds(rel, src, r"^ASR_PORT=\$\(\(PORT \+ (\d+)\)\)$")
|
||||
p.same(f"{where} its ASR_PORT", [f["ports"][0] + int(x) for x in got], f["ports"][1:])
|
||||
# the OvisOCR3 lane's engine, on a port of its own behind its front (its installer's ENGINE_PORT)
|
||||
engine, _ = finds(rel, src, r'^ENGINE_PORT="\$\{OCR_ENGINE_PORT:-[^\n]*\}"; ENGINE_PORT="\$\{ENGINE_PORT:-(\d+)\}"$')
|
||||
p.same(f"{where} its ASR_PORT and ENGINE_PORT", [f["ports"][0] + int(x) for x in got] + [int(x) for x in engine], f["ports"][1:])
|
||||
m, where = one("speech-server.py", text_of("speech-server.py"),
|
||||
r'add_argument\("--port", type=int, default=(\d+)\)\n\s*ap\.add_argument\("--asr-url", default="http://127\.0\.0\.1:(\d+)"\)')
|
||||
p.same(f"{where} its --port and --asr-url", [int(x) for x in m.groups()], LANES["speech"]["ports"])
|
||||
|
||||
Reference in new issue
Block a user