summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/perl/dist/Net-Ping/t/010_pingecho.t
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/perl/dist/Net-Ping/t/010_pingecho.t')
-rw-r--r--gnu/usr.bin/perl/dist/Net-Ping/t/010_pingecho.t19
1 files changed, 19 insertions, 0 deletions
diff --git a/gnu/usr.bin/perl/dist/Net-Ping/t/010_pingecho.t b/gnu/usr.bin/perl/dist/Net-Ping/t/010_pingecho.t
new file mode 100644
index 00000000000..90a934a0b10
--- /dev/null
+++ b/gnu/usr.bin/perl/dist/Net-Ping/t/010_pingecho.t
@@ -0,0 +1,19 @@
+use warnings;
+use strict;
+
+BEGIN {
+ unless (my $port = getservbyname('echo', 'tcp')) {
+ print "1..0 \# Skip: no echo port\n";
+ exit;
+ }
+}
+
+use Test::More tests => 2;
+BEGIN {use_ok('Net::Ping')};
+
+TODO: {
+ local $TODO = "Not working on os390 smoker; may be a permissions problem"
+ if $^O eq 'os390';
+ my $result = pingecho("127.0.0.1");
+ is($result, 1, "pingecho works");
+}