File: resolver.t

package info (click to toggle)
libemail-valid-perl 1.204-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 336 kB
  • sloc: perl: 3,157; makefile: 7
file content (20 lines) | stat: -rw-r--r-- 495 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!perl
use strict;
use Test::More;

if (!eval { require Net::DNS; 1 }) {
    plan skip_all => 'only relevant if Net::DNS is installed';
}
else {
    plan tests => 4;
}

# not yet loaded, so resolver should be undef
ok !defined $Email::Valid::Resolver, 'resolver is undef';

# load module, which calls import(), initializing resolver
use_ok('Email::Valid');

# check resolver object
ok defined $Email::Valid::Resolver, 'resover initialized';
isa_ok $Email::Valid::Resolver, 'Net::DNS::Resolver';