in reply to PERL_ANYEVENT_NET_TESTS environment variable not set

If only test fails you can skip tests with cpan force install AnyEvent and hope evrything else run fine.

Anyway message you got seems to me unharmful: that env var $ENV{PERL_ANYEVENT_NET_TESTS} was not found and some test were skipped. Just for sake of curiosity you can try to set that env var and watch what change.

The main error seems a line after: t/handle/04_listen.t ....... [METAMOD://AnyEvent::Handle] uncaught error: Connection refused at /root/.cpan/build/AnyEvent-7.12-JRk62y/blib/lib/AnyEvent/Socket.pm line 1000.

L*

There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.