[libsocket-perl] 01/02: Disable network tests during build.
gregor herrmann
gregoa at debian.org
Fri Aug 12 18:50:55 UTC 2016
This is an automated email from the git hooks/post-receive script.
gregoa pushed a commit to branch master
in repository libsocket-perl.
commit 1a3edf4d02983d6327fbc683157a6a9d3e0c0756
Author: gregor herrmann <gregoa at debian.org>
Date: Fri Aug 12 20:48:53 2016 +0200
Disable network tests during build.
---
debian/patches/disable-network-tests.patch | 32 ++++++++++++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 3 +++
3 files changed, 36 insertions(+)
diff --git a/debian/patches/disable-network-tests.patch b/debian/patches/disable-network-tests.patch
new file mode 100644
index 0000000..ce0d462
--- /dev/null
+++ b/debian/patches/disable-network-tests.patch
@@ -0,0 +1,32 @@
+Description: skip network tests
+Origin: vendor
+Forwarded: not needed
+Author: gregor herrmann <gregoa at debian.org>
+Last-Update: 2016-08-12
+
+--- a/t/getaddrinfo.t
++++ b/t/getaddrinfo.t
+@@ -70,6 +70,7 @@
+ my $goodhost = "cpan.perl.org";
+
+ SKIP: {
++ skip "No network access during Debian builds", 2 if $ENV{NO_NETWORK};
+ skip "Resolver has no answer for $goodhost", 2 unless gethostbyname( $goodhost );
+
+ ( $err, @res ) = getaddrinfo( "cpan.perl.org", "ftp", { socktype => SOCK_STREAM } );
+@@ -85,6 +86,7 @@
+ # any request. We'd better check for them
+
+ SKIP: {
++ skip "No network access during Debian builds", 1 if $ENV{NO_NETWORK};
+ skip "Resolver has an answer for $missinghost", 1 if gethostbyname( $missinghost );
+
+ # Some OSes return $err == 0 but no results
+@@ -124,6 +126,7 @@
+ # Now check that names with AI_NUMERICHOST fail
+
+ SKIP: {
++ skip "No network access during Debian builds", 1 if $ENV{NO_NETWORK};
+ skip "Resolver has no answer for $goodhost", 1 unless gethostbyname( $goodhost );
+
+ ( $err, @res ) = getaddrinfo( $goodhost, "ftp", { flags => AI_NUMERICHOST, socktype => SOCK_STREAM } );
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..ac5717b
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+disable-network-tests.patch
diff --git a/debian/rules b/debian/rules
index 73c5dbc..0113a4f 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,3 +4,6 @@ export DEB_BUILD_MAINT_OPTIONS = hardening=+bindnow
%:
dh $@
+
+override_dh_auto_test:
+ NO_NETWORK=1 dh_auto_test
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libsocket-perl.git
More information about the Pkg-perl-cvs-commits
mailing list