chore(codegen): drop dead c == "" branch in test-name validation

`c` iterates one character at a time over the test name string;
a single character is never the empty string, so the disjunct was
always False. The remaining `0x20 <= ord(c) < 0x7F` already
correctly rejects non-ASCII names, so behaviour is unchanged.
This commit is contained in:
okhsunrog 2026-04-26 15:45:42 +03:00
parent 87a2041b88
commit a0bec24576

View file

@ -134,7 +134,7 @@ def parse_test(entry: dict[str, Any]) -> TestVector:
if "name" not in entry or "is_vpn" not in entry:
raise SystemExit(f"[[test]] entry needs name and is_vpn: {entry!r}")
name = str(entry["name"])
if not all(c == "" or 0x20 <= ord(c) < 0x7F for c in name):
if not all(0x20 <= ord(c) < 0x7F for c in name):
raise SystemExit(f"non-ASCII test name {name!r}; the matcher itself is ASCII-only")
return TestVector(name=name, is_vpn=bool(entry["is_vpn"]))