From d9b6d52a8c203eb69abd94ab875777159f2dfd25 Mon Sep 17 00:00:00 2001 From: Erik Auerswald Date: Sat, 26 Apr 2025 18:19:13 +0200 Subject: [PATCH] restore inadvertantly removed IPv4 test for -k This was removed in an commit by me that should only have added a new test (commit 4160d03a2653684b37a776744095aac43f7efc88). --- ci/test-11-unpriv.pl | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/ci/test-11-unpriv.pl b/ci/test-11-unpriv.pl index 5b5705d..6ec0768 100755 --- a/ci/test-11-unpriv.pl +++ b/ci/test-11-unpriv.pl @@ -40,7 +40,7 @@ else { } sub test_unprivileged_works { - plan tests => 15; + plan tests => 18; { my $cmd = Test::Command->new(cmd => "$fping_copy 127.0.0.1"); @@ -60,6 +60,15 @@ sub test_unprivileged_works { $cmd->stdout_is_eq("127.0.0.1 is alive (TTL unknown)\n"); $cmd->stderr_is_eq(""); } + SKIP: { + if($^O ne 'linux') { + skip '-k option is only supported on Linux', 3; + } + my $cmd = Test::Command->new(cmd => "$fping_copy -4 -k 256 127.0.0.1"); + $cmd->exit_is_num(0); + $cmd->stdout_is_eq("127.0.0.1 is alive\n"); + $cmd->stderr_like(qr{fwmark ipv4: .+\n}); + } SKIP: { if($^O ne 'linux') { skip '-k option is only supported on Linux', 3; -- 2.43.0