Zonemaster::Engine::Test::Zone(3p)

NAME
Zonemaster::Engine::Test::Zone - Module implementing tests focused on the DNS zone content, such as SOA and MX records

SYNOPSIS
    my @results = Zonemaster::Engine::Test::Zone->all( $zone );

METHODS

all()
        my @logentry_array = all( $zone );

    Runs the default set of tests for that module, i.e. between eight and ten tests depending on the tested zone.

    Takes a Zonemaster::Engine::Zone object.

    Returns a list of Zonemaster::Engine::Logger::Entry objects.

metadata()
        my $hash_ref = metadata();

    Returns a reference to a hash, the keys of which are the names of all Test Cases in the module, and the corresponding values are references to an array containing all the message tags that the Test Case can use in log entries.

tag_descriptions()
        my $hash_ref = tag_descriptions();

    Used by the built-in translation system.

    Returns a reference to a hash, the keys of which are the message tags and the corresponding values are strings (message IDs).

version()
        my $version_string = version();

    Returns a string containing the version of the current module.

INTERNAL METHODS

_emit_log()
        my $log_entry = _emit_log( $message_tag_string, $hash_ref );

    Adds a message to the logger for this module. See "add($tag, $argref, $module, $testcase)" in Zonemaster::Engine::Logger::Entry for more details.

    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 if the IP version of a given name server is allowed to be queried. If not, it adds a logging message and returns true. Else, it returns false.

    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 given type for the given name from the response of the first authoritative server of the given zone that has at least one. Used as an 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".

_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).

TESTS

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.