On Wed Oct 26 08:59:06 2016, NHORNE wrote:
Show quoted text> I think the problem is here in 500_ping_icmp.t:
>
> if (!Net::Ping::_isroot()) {
> my $file = __FILE__;
> diag 'This optional test may prompt for your sudo password.';
> if (system("sudo \"$^X\" -Mblib $file") == 0) {
> exit;
> } else {
> plan skip_all => 'no sudo/failed';
> }
> }
>
> I don't like random code trying to sudo. Perhaps this should be an
> "author only" test?
Yes, I don't like it neither. But it caught a longstanding bug, because nobody so far ever executed that function, because nobody apparently tested that as root.
So either add a timeout or change it to AUTHOR_TESTING only.
Catch is, I never run AUTHOR_TESTING in perl core, so I would never catch that.
--
Reini Urban