From c3bb07c4ad758c1cbf772e3652e3012ae712deef Mon Sep 17 00:00:00 2001 From: Shoichi Kaji Date: Wed, 31 Jul 2019 22:49:43 +0900 Subject: [PATCH 1/3] test requires HTTP::Daemon 6.05 --- t/local/back.t | 2 +- t/local/log-server | 2 +- t/local/referer-server | 2 +- t/local/referer.t | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/t/local/back.t b/t/local/back.t index 0ad2757..b3b1641 100644 --- a/t/local/back.t +++ b/t/local/back.t @@ -3,7 +3,7 @@ use strict; use Test::More tests => 47; use lib qw( t t/local ); use LocalServer; -use HTTP::Daemon; +use HTTP::Daemon 6.05; use HTTP::Response; diff --git a/t/local/log-server b/t/local/log-server index d43cb44..4c2f458 100644 --- a/t/local/log-server +++ b/t/local/log-server @@ -1,6 +1,6 @@ # Thanks to merlyn for nudging me and giving me this snippet! use strict; -use HTTP::Daemon; +use HTTP::Daemon 6.05; use CGI 4.08; use Getopt::Long; diff --git a/t/local/referer-server b/t/local/referer-server index 2c01bc0..4f555a5 100644 --- a/t/local/referer-server +++ b/t/local/referer-server @@ -1,6 +1,6 @@ # Thanks to merlyn for nudging me and giving me this snippet! -use HTTP::Daemon; +use HTTP::Daemon 6.05; use URI::URL; $|++; diff --git a/t/local/referer.t b/t/local/referer.t index ef5a7ce..87dadaa 100644 --- a/t/local/referer.t +++ b/t/local/referer.t @@ -19,7 +19,7 @@ my $agent = WWW::Mechanize->new(); isa_ok( $agent, 'WWW::Mechanize' ); SKIP: { - eval { require HTTP::Daemon; }; + eval { require HTTP::Daemon; HTTP::Daemon->VERSION(6.05); }; skip 'HTTP::Daemon required to test the referrer header',10 if $@; # We want to be safe from non-resolving local host names -- 2.1.4 From c60cf1cb94f41fcfd09c01fd731c9be484f23eab Mon Sep 17 00:00:00 2001 From: Shoichi Kaji Date: Thu, 1 Aug 2019 00:41:47 +0900 Subject: [PATCH 2/3] use localhost notations in t/local --- t/local/LocalServer.pm | 2 +- t/local/referer-server | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/t/local/LocalServer.pm b/t/local/LocalServer.pm index c05baee..5e9bdfb 100644 --- a/t/local/LocalServer.pm +++ b/t/local/LocalServer.pm @@ -115,7 +115,7 @@ sub spawn { # What is this code supposed to fix? my $lhurl = URI::URL->new( $url ); - $lhurl->host( '127.0.0.1' ); + $lhurl->host( 'localhost' ); $self->{_server_url} = $lhurl; $self->{_fh} = $server; diff --git a/t/local/referer-server b/t/local/referer-server index 4f555a5..54eaf8d 100644 --- a/t/local/referer-server +++ b/t/local/referer-server @@ -7,7 +7,7 @@ $|++; my $d = HTTP::Daemon->new or die; my $lhurl = URI::URL->new( $d->url ); -$lhurl->host( "127.0.0.1" ); +$lhurl->host( 'localhost' ); print $lhurl->as_string, "\n"; $counter = 5; -- 2.1.4 From 68af39e8f84e10a785973e123c40d912e7b99375 Mon Sep 17 00:00:00 2001 From: Shoichi Kaji Date: Fri, 9 Aug 2019 02:04:10 +0300 Subject: [PATCH 3/3] manually bump HTTP::Daemon --- META.json | 2 +- Makefile.PL | 4 ++-- cpanfile | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/META.json b/META.json index 46464ca..155dabd 100644 --- a/META.json +++ b/META.json @@ -87,7 +87,7 @@ "File::Spec" : "0", "File::Temp" : "0", "FindBin" : "0", - "HTTP::Daemon" : "0", + "HTTP::Daemon" : "6.05", "HTTP::Response" : "0", "HTTP::Server::Simple::CGI" : "0", "LWP" : "0", diff --git a/Makefile.PL b/Makefile.PL index 2f0eb82..19101bf 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -46,7 +46,7 @@ my %WriteMakefileArgs = ( "File::Spec" => 0, "File::Temp" => 0, "FindBin" => 0, - "HTTP::Daemon" => 0, + "HTTP::Daemon" => "6.05", "HTTP::Response" => 0, "HTTP::Server::Simple::CGI" => 0, "LWP" => 0, @@ -83,7 +83,7 @@ my %FallbackPrereqs = ( "HTML::TokeParser" => 0, "HTML::TreeBuilder" => 5, "HTTP::Cookies" => 0, - "HTTP::Daemon" => 0, + "HTTP::Daemon" => "6.05", "HTTP::Request" => "1.30", "HTTP::Request::Common" => 0, "HTTP::Response" => 0, diff --git a/cpanfile b/cpanfile index 0b715c0..182440c 100644 --- a/cpanfile +++ b/cpanfile @@ -25,7 +25,7 @@ on 'test' => sub { requires "File::Spec" => "0"; requires "File::Temp" => "0"; requires "FindBin" => "0"; - requires "HTTP::Daemon" => "0"; + requires "HTTP::Daemon" => "6.05"; requires "HTTP::Response" => "0"; requires "HTTP::Server::Simple::CGI" => "0"; requires "LWP" => "0"; -- 2.1.4