#!/usr/bin/perl -w
-use Test::Command tests => 44;
+use Test::Command tests => 47;
use Test::More;
use Time::HiRes qw(gettimeofday tv_interval);
$cmd->stderr_is_eq("");
}
+# fping --icmp-timestamp -b
+{
+my $cmd = Test::Command->new(cmd => "fping --icmp-timestamp -b 1000 127.0.0.1");
+$cmd->exit_is_num(1);
+$cmd->stdout_is_eq("");
+$cmd->stderr_like(qr{Usage:});
+}
+
# fping -B
SKIP: {
if($^O eq 'darwin') {
case 'b':
if (sscanf(optparse_state.optarg, "%u", &ping_data_size) != 1)
usage(1);
+ if (icmp_request_typ > 0)
+ usage(1);
break;
fprintf(out, " -t, --timeout=MSEC individual target initial timeout (default: %.0f ms,\n", timeout / 1e6);
fprintf(out, " except with -l/-c/-C, where it's the -p period up to 2000 ms)\n");
fprintf(out, " --check-source discard replies not from target address\n");
- fprintf(out, " --icmp-timestamp send ping type Timestamp Request\n");
+ fprintf(out, " --icmp-timestamp send ping type Timestamp Request (only if no -b specified)\n");
fprintf(out, "\n");
fprintf(out, "Output options:\n");
fprintf(out, " -a, --alive show targets that are alive\n");