Zonema...::Zone(3pm)
π Zonema...::Zone(3pm) β the zone content test module π
okay bestie, welcome to Zonemaster::Engine::Test::Zone π this is the Perl module that runs the tests focused on the DNS zone content, like SOA and MX records. it lives in the User Contributed Perl Documentation, section 3pm, and it is genuinely one of the most useful things in the whole Zonemaster engine, no cap π
β¨ SYNOPSIS β¨
like, the whole vibe in one line:
my @results = Zonemaster::Engine::Test::Zone->all( $zone );
πΈ METHODS πΈ
all()
my @logentry_array = all( $zone );
runs the default set of tests for that module β so like, between eight and ten tests, depending on the zone you're testing π¦ (yes, the count is vibe-dependent, that's not a bug, that's just how the zone crumbles).
it takes a Zonemaster::Engine::Zone object.
it returns a list of Zonemaster::Engine::Logger::Entry objects. periodt.
metadata()
my $hash_ref = metadata();
hands you back a reference to a hash π the keys are the names of all Test Cases in the module, and the corresponding values are references to an array holding all the message tags that that Test Case can use in log entries. iykyk.
tag_descriptions()
my $hash_ref = tag_descriptions();
this one is used by the built-in translation system π§
returns a reference to a hash where the keys are the message tags and the values are strings (message IDs).
version()
my $version_string = version();
returns a string with the version of the current module. iconic behavior honestly β
π₯ INTERNAL METHODS π₯
heads up bestie, these are internal β they're not your main character energy, they're the backstage crew making the whole show work π
_emit_log()
my $log_entry = _emit_log( $message_tag_string, $hash_ref );
adds a message to the logger for this module π
go check "add($tag, $argref, $module, $testcase)" in Zonemaster::Engine::Logger::Entry if you want the full lore.
takes a string (message tag) and a reference to a hash (arguments).
returns a Zonemaster::Engine::Logger::Entry object.
_ip_disabled_message()
my $bool = _ip_disabled_message( $logentry_array_ref, $ns, @query_type_string );
checks whether the IP version of a given name server is even allowed to be queried π if it's not allowed, it adds a logging message and returns true. otherwise it returns false. simple as.
takes a reference to an array of Zonemaster::Engine::Logger::Entry objects, a Zonemaster::Engine::Nameserver object and an array of strings (query type).
returns a boolean.
_retrieve_record_from_zone()
my $packet = _retrieve_record_from_zone( $logentry_array_ref, $zone, $name, $query_type_string );
retrieves resource records of the given type for the given name, from the response of the first authoritative server of the given zone that has at least one π¦ this is a helper function for Test Cases Zone02 to Zone07.
takes a reference to an array of Zonemaster::Engine::Logger::Entry objects, a Zonemaster::Engine::Zone object, a Zonemaster::Engine::DNSName object and a string (query type).
returns a Zonemaster::Engine::Packet object, or undef. (yeah, undef. it's giving "it depends" π)
_spf_syntax_ok()
_spf_syntax_ok( $spf_string );
attempts to run "new_from_string($text, %options)" in Mail::SPF::v1::Record on the provided string β¨
takes a string (SPF text). that's it. that's the whole thing.
π TESTS π
okay so this is the main event, the whole roster, the lineup π every single one of these takes a Zonemaster::Engine::Zone object and returns a list of Zonemaster::Engine::Logger::Entry objects. every single one. no exceptions. we love consistency π
zone01()
my @logentry_array = zone01( $zone );
runs the Zone01 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone01.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone02()
my @logentry_array = zone02( $zone );
runs the Zone02 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone02.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone03()
my @logentry_array = zone03( $zone );
runs the Zone03 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone03.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone04()
my @logentry_array = zone04( $zone );
runs the Zone04 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone04.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone05()
my @logentry_array = zone05( $zone );
runs the Zone05 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone05.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone06()
my @logentry_array = zone06( $zone );
runs the Zone06 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone06.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone07()
my @logentry_array = zone07( $zone );
runs the Zone07 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone07.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone08()
my @logentry_array = zone08( $zone );
runs the Zone08 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone08.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone09()
my @logentry_array = zone09( $zone );
runs the Zone09 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone09.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone10()
my @logentry_array = zone10( $zone );
runs the Zone10 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone10.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
zone11()
my @logentry_array = zone11( $zone );
runs the Zone11 Test Case β https://github.com/zonemaster/zonemaster/blob/master/docs/public/specifications/tests/Zone-TP/zone11.md
takes a Zonemaster::Engine::Zone object.
returns a list of Zonemaster::Engine::Logger::Entry objects.
that's the whole roster bestie, eleven zones, four helper internals, and one extremely efficient all() that does the most for you π«Ά
and that's a wrap!! πβ¨ this page is from the User Contributed Perl Documentation, generated with perl v5.40.1 on 2026-03-21. slay, go test your zone, mwah π
ππ¦
π¦ where this page comes from
- ubuntu stonking: libzonemaster-perl 8.001.001-1 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms