Blame SOURCES/Net-Ping-2.74-Use-non-routable-addreses-for-negative-tests.patch

13b96b
From a42c6588e33a1d6d847b60ef3386bfd122ce030b Mon Sep 17 00:00:00 2001
13b96b
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
13b96b
Date: Wed, 18 Nov 2020 09:49:48 +0100
13b96b
Subject: [PATCH 1/2] Use non-routable addreses for negative tests
13b96b
MIME-Version: 1.0
13b96b
Content-Type: text/plain; charset=UTF-8
13b96b
Content-Transfer-Encoding: 8bit
13b96b
13b96b
This patch uses the addresses reserved for a documentation purpose
13b96b
which should be unroutable instead of just a random address.
13b96b
13b96b
Signed-off-by: Petr Písař <ppisar@redhat.com>
13b96b
---
13b96b
 t/190_alarm.t         | 2 +-
13b96b
 t/200_ping_tcp.t      | 2 +-
13b96b
 t/400_ping_syn.t      | 2 +-
13b96b
 t/410_syn_host.t      | 2 +-
13b96b
 t/420_ping_syn_port.t | 2 +-
13b96b
 t/501_ping_icmpv6.t   | 2 +-
13b96b
 6 files changed, 6 insertions(+), 6 deletions(-)
13b96b
13b96b
diff --git a/t/190_alarm.t b/t/190_alarm.t
13b96b
index 65276a2..f86305c 100644
13b96b
--- a/t/190_alarm.t
13b96b
+++ b/t/190_alarm.t
13b96b
@@ -29,7 +29,7 @@ use Test::More tests => 6;
13b96b
 BEGIN {use_ok 'Net::Ping'};
13b96b
 
13b96b
 # Hopefully this is never a routeable host
13b96b
-my $fail_ip = $ENV{NET_PING_FAIL_IP} || "172.29.249.249";
13b96b
+my $fail_ip = $ENV{NET_PING_FAIL_IP} || "192.0.2.0";
13b96b
 
13b96b
 eval {
13b96b
   my $timeout = 11;
13b96b
diff --git a/t/200_ping_tcp.t b/t/200_ping_tcp.t
13b96b
index e2bfe18..8e8f56d 100644
13b96b
--- a/t/200_ping_tcp.t
13b96b
+++ b/t/200_ping_tcp.t
13b96b
@@ -18,7 +18,7 @@ BEGIN {
13b96b
 }
13b96b
 
13b96b
 # Hopefully this is never a routeable host
13b96b
-my $fail_ip = $ENV{NET_PING_FAIL_IP} || "172.29.249.249";
13b96b
+my $fail_ip = $ENV{NET_PING_FAIL_IP} || "192.0.2.0";
13b96b
 
13b96b
 # Remote network test using tcp protocol.
13b96b
 #
13b96b
diff --git a/t/400_ping_syn.t b/t/400_ping_syn.t
13b96b
index 1ccec9f..8409aae 100644
13b96b
--- a/t/400_ping_syn.t
13b96b
+++ b/t/400_ping_syn.t
13b96b
@@ -33,7 +33,7 @@ BEGIN {
13b96b
 # $ PERL_CORE=1 make test
13b96b
 
13b96b
 # Hopefully this is never a routeable host
13b96b
-my $fail_ip = $ENV{NET_PING_FAIL_IP} || "172.29.249.249";
13b96b
+my $fail_ip = $ENV{NET_PING_FAIL_IP} || "192.0.2.0";
13b96b
 
13b96b
 # Try a few remote servers
13b96b
 my %webs = (
13b96b
diff --git a/t/410_syn_host.t b/t/410_syn_host.t
13b96b
index d84a7eb..15948e2 100644
13b96b
--- a/t/410_syn_host.t
13b96b
+++ b/t/410_syn_host.t
13b96b
@@ -37,7 +37,7 @@ BEGIN {
13b96b
 my %webs;
13b96b
 BEGIN {
13b96b
   # Hopefully this is never a routeable host
13b96b
-  my $fail_ip = $ENV{NET_PING_FAIL_IP} || "172.29.249.249";
13b96b
+  my $fail_ip = $ENV{NET_PING_FAIL_IP} || "192.0.2.0";
13b96b
 
13b96b
   %webs = (
13b96b
   $fail_ip => 0,
13b96b
diff --git a/t/420_ping_syn_port.t b/t/420_ping_syn_port.t
13b96b
index 55ee88a..53c153f 100644
13b96b
--- a/t/420_ping_syn_port.t
13b96b
+++ b/t/420_ping_syn_port.t
13b96b
@@ -34,7 +34,7 @@ BEGIN {
13b96b
 # $ PERL_CORE=1 make test
13b96b
 
13b96b
 # Hopefully this is never a routeable host
13b96b
-my $fail_ip = $ENV{NET_PING_FAIL_IP} || "172.29.249.249";
13b96b
+my $fail_ip = $ENV{NET_PING_FAIL_IP} || "192.0.2.0";
13b96b
 
13b96b
 # Try a few remote servers
13b96b
 my %webs;
13b96b
diff --git a/t/501_ping_icmpv6.t b/t/501_ping_icmpv6.t
13b96b
index 3d2b789..165824f 100644
13b96b
--- a/t/501_ping_icmpv6.t
13b96b
+++ b/t/501_ping_icmpv6.t
13b96b
@@ -59,7 +59,7 @@ SKIP: {
13b96b
   my $rightip = "2001:4860:4860::8888"; # pingable ip of google's dnsserver
13b96b
   # for a firewalled ipv6 network try an optional local ipv6 host
13b96b
   $rightip = $ENV{TEST_PING6_HOST} if $ENV{TEST_PING6_HOST};
13b96b
-  my $wrongip = "2001:4860:4860::1234"; # non existing ip
13b96b
+  my $wrongip = "2001:db8::"; # non existing ip
13b96b
   # diag "Pinging existing IPv6 ";
13b96b
   my $result = $p->ping($rightip);
13b96b
   if ($result == 1) {
13b96b
-- 
13b96b
2.25.4
13b96b