diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-11-22 04:45:36 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-11-22 04:45:36 +0000 |
commit | 0cf115ef1b426406ab4344439c6ffcb9ee04d4c4 (patch) | |
tree | a6ec9bd680c188c048cb00d733b78220e020d852 /lib/Net | |
parent | 2e2a97a6830e320aea4080daa62a7cee8c91e9df (diff) | |
download | perl-0cf115ef1b426406ab4344439c6ffcb9ee04d4c4.tar.gz |
Corify the Net::Ping tests; skip the tests
unless $ENV{PERL_TEST_Net_Ping} is true.
p4raw-id: //depot/perl@13190
Diffstat (limited to 'lib/Net')
-rw-r--r-- | lib/Net/Ping/t/100_load.t | 11 | ||||
-rw-r--r-- | lib/Net/Ping/t/110_icmp_inst.t | 11 | ||||
-rw-r--r-- | lib/Net/Ping/t/120_udp_inst.t | 11 | ||||
-rw-r--r-- | lib/Net/Ping/t/130_tcp_inst.t | 11 | ||||
-rw-r--r-- | lib/Net/Ping/t/200_ping_tcp.t | 11 |
5 files changed, 55 insertions, 0 deletions
diff --git a/lib/Net/Ping/t/100_load.t b/lib/Net/Ping/t/100_load.t index d6a71e0235..c5115f74ad 100644 --- a/lib/Net/Ping/t/100_load.t +++ b/lib/Net/Ping/t/100_load.t @@ -1,3 +1,14 @@ +BEGIN { + if ($ENV{PERL_CORE}) { + unless ($ENV{PERL_TEST_Net_Ping}) { + print "1..0 # Skip: network dependent test\n"; + exit; + } + chdir 't' if -d 't'; + @INC = qw(../lib); + } +} + # Before `make install' is performed this script should be runnable with # `make test'. After `make install' it should work as `perl test.t' diff --git a/lib/Net/Ping/t/110_icmp_inst.t b/lib/Net/Ping/t/110_icmp_inst.t index 2e67a5972a..215d46c554 100644 --- a/lib/Net/Ping/t/110_icmp_inst.t +++ b/lib/Net/Ping/t/110_icmp_inst.t @@ -1,3 +1,14 @@ +BEGIN { + if ($ENV{PERL_CORE}) { + unless ($ENV{PERL_TEST_Net_Ping}) { + print "1..0 # Skip: network dependent test\n"; + exit; + } + chdir 't' if -d 't'; + @INC = qw(../lib); + } +} + # Test to make sure object can be instantiated for icmp protocol. # Root access is required to actually perform icmp testing. diff --git a/lib/Net/Ping/t/120_udp_inst.t b/lib/Net/Ping/t/120_udp_inst.t index ee53bd40bf..51d1dac1fc 100644 --- a/lib/Net/Ping/t/120_udp_inst.t +++ b/lib/Net/Ping/t/120_udp_inst.t @@ -1,3 +1,14 @@ +BEGIN { + if ($ENV{PERL_CORE}) { + unless ($ENV{PERL_TEST_Net_Ping}) { + print "1..0 # Skip: network dependent test\n"; + exit; + } + chdir 't' if -d 't'; + @INC = qw(../lib); + } +} + # Test to make sure object can be instantiated for udp protocol. # I do not know of any servers that support udp echo anymore. diff --git a/lib/Net/Ping/t/130_tcp_inst.t b/lib/Net/Ping/t/130_tcp_inst.t index 6a547e161e..30db8bd031 100644 --- a/lib/Net/Ping/t/130_tcp_inst.t +++ b/lib/Net/Ping/t/130_tcp_inst.t @@ -1,3 +1,14 @@ +BEGIN { + if ($ENV{PERL_CORE}) { + unless ($ENV{PERL_TEST_Net_Ping}) { + print "1..0 # Skip: network dependent test\n"; + exit; + } + chdir 't' if -d 't'; + @INC = qw(../lib); + } +} + # Test to make sure object can be instantiated for tcp protocol. use Test; diff --git a/lib/Net/Ping/t/200_ping_tcp.t b/lib/Net/Ping/t/200_ping_tcp.t index 3f5c6bc417..2aa4eecf61 100644 --- a/lib/Net/Ping/t/200_ping_tcp.t +++ b/lib/Net/Ping/t/200_ping_tcp.t @@ -1,3 +1,14 @@ +BEGIN { + if ($ENV{PERL_CORE}) { + unless ($ENV{PERL_TEST_Net_Ping}) { + print "1..0 # Skip: network dependent test\n"; + exit; + } + chdir 't' if -d 't'; + @INC = qw(../lib); + } +} + # Remote network test using tcp protocol. # # NOTE: |