| Revision: | 1.2 |
| Committed: | Sat May 5 23:20:24 2007 UTC (19 years, 5 months ago) by root |
| Content type: | application/x-troff |
| Branch: | MAIN |
| CVS Tags: | rel-0_9, rel-0_02 |
| Changes since 1.1: | +2 -0 lines |
| Log Message: | *** empty log message *** |
| # | User | Rev | Content |
|---|---|---|---|
| 1 | root | 1.2 | BEGIN { $> and do { print "1..0 # skipped: will only run ping tests as root\n"; exit } } |
| 2 | |||
| 3 | root | 1.1 | print "1..4\n"; |
| 4 | |||
| 5 | use strict; | ||
| 6 | use Net::FPing; | ||
| 7 | |||
| 8 | use AnyEvent; | ||
| 9 | |||
| 10 | my $done = AnyEvent->condvar; | ||
| 11 | |||
| 12 | print "ok 1\n"; | ||
| 13 | |||
| 14 | Net::FPing::icmp_ping | ||
| 15 | [[v127.0.0.1, v127.0.0.255], [v127.0.1.1, v127.0.1.5, 0.05]], 0, 0, | ||
| 16 | sub { print "ok 3\n"; $done->broadcast }; | ||
| 17 | |||
| 18 | print "ok 2\n"; | ||
| 19 | |||
| 20 | $done->wait; | ||
| 21 | |||
| 22 | print "ok 4\n"; |