]> git.ipfire.org Git - thirdparty/bind9.git/commit
Migrate digdelv dig formatting checks to pytest
authorMartin Basti <mbasti@isc.org>
Wed, 22 Jul 2026 14:08:43 +0000 (14:08 +0000)
committerMartin Basti <mbasti@isc.org>
Wed, 29 Jul 2026 11:52:25 +0000 (13:52 +0200)
commit8d169d554e658ef4870d8202083511fcaaae78ac
tree2611e6e5d7bf803325ba608e4b5f3561d63cf918
parentf2f83a768ca3c90a60af2db6950edcd18d0dbdad
Migrate digdelv dig formatting checks to pytest

Move the dig output-formatting and command-line handling checks from
tests.sh into a new tests_dig.py module: +short, +split/+sp,
+unknownformat, reverse lookups, the rrcomments/multi matrix,
+header-only, +ttlunits, +expandaaaa, +bufsize, query-time units and
+yaml timestamp precision, +nocrypto, class CHAOS, query-name error
handling and the UPDATE-opcode rejection.  Repeated checks are
parametrized and the duplicated "+short +rrcomments" check is folded
into a single test.

The shared check_ttl_range helper mirrors the original awk check: it
scans the output line by line, accepts the class tokens IN and CLASS1
(the RFC 3597 unknown-format spelling), and compares the RR type
token textually and the TTL numerically.

Assisted-by: Claude:claude-fable-5
bin/tests/system/digdelv/common.py
bin/tests/system/digdelv/conftest.py [new file with mode: 0644]
bin/tests/system/digdelv/tests.sh
bin/tests/system/digdelv/tests_dig.py [new file with mode: 0644]