libwww-perl / WWW-Mechanize

Handy web browsing in a Perl object
https://metacpan.org/pod/WWW::Mechanize
Other
68 stars 52 forks source link

test requires HTTP::Daemon 6.05+ and use 127.0.0.1 or [::1] according to server's sockdomain #280

Closed skaji closed 5 years ago

skaji commented 5 years ago

We saw some test failures related IPv4/IPv6 (eg #278 #272 #101).

Now HTTP::Daemon 6.05 uses IO::Socket::IP, and IO::Socket::IP takes care of IPv4/IPv6, so we should use "localhost" notations and let IO::Socket::IP select IPv4/IPv6 automatically.

Note:

coveralls commented 5 years ago

Pull Request Test Coverage Report for Build 273


Totals Coverage Status
Change from base Build 265: 0.0%
Covered Lines: 725
Relevant Lines: 782

💛 - Coveralls
oalders commented 5 years ago

@skaji is this ready to merge?

skaji commented 5 years ago

I have cherry-picked a commit from patch2 branch 7d796b8. jkeenan confirmed that tests passed with the commit https://github.com/libwww-perl/HTTP-Daemon/issues/33#issuecomment-523700091.

@oalders If travis ci passes, I think this PR is ready to merge!

jkeenan commented 5 years ago

The CPANtester who originally reported the bad interaction between HTTP::Daemon and WWW::Mechanize (causing his rigs to hang indefinitely) has reported to me that skaji's branch patch2 corrects that problem. We are therefore eager to see a new WWW::Mechanize release to CPAN as soon as possible.

A new CPAN release is likely to resolve these 3 issues in your queue: https://github.com/libwww-perl/WWW-Mechanize/issues/253 https://github.com/libwww-perl/WWW-Mechanize/issues/278 https://github.com/libwww-perl/WWW-Mechanize/issues/281

Thank you very much. Jim Keenan

oalders commented 5 years ago

Thanks @skaji, @eserte and @jkeenan!

Corion commented 5 years ago

Thank you all for fixing this! The log-server program at some time split off into its own CPAN module at Test::HTTP::LocalServer, where I added this fix as well!

I'll look into updating the program in WWW::Mechanize from Test::HTTP::LocalServer if I have features that the WWW::Mechanize distribution needs.