From 21a662b1ee23bbcb2c7eb48a8e3abe745187d19a Mon Sep 17 00:00:00 2001 From: =?utf8?q?P=C3=A1draig=20Brady?=
Date: Wed, 28 May 2025 20:48:31 +0100 Subject: [PATCH] tests: sort: expand multiple output testing * tests/sort/sort.pl: Ensure duplicate output strings are supported. --- tests/sort/sort.pl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/sort/sort.pl b/tests/sort/sort.pl index 2ee92c4574..5fa9d52527 100755 --- a/tests/sort/sort.pl +++ b/tests/sort/sort.pl @@ -350,6 +350,11 @@ my @Tests = # Specifying two -o options should evoke a failure ["o2", qw(-o x -o y), {EXIT=>2}, {ERR=>"foo\n"}, {ERR_SUBST => 's/^$prog: .*/foo/'}], +# Specifying duplicate -o options should NOT evoke a failure +["o3", qw(-o x -o x), {IN=>""}, {OUT=>""}], +# Note we do simple string comparisons for this +["o4", qw(-o x -o ./x), {EXIT=>2}, + {ERR=>"foo\n"}, {ERR_SUBST => 's/^$prog: .*/foo/'}], # Specifying incompatible options should evoke a failure. ["incompat1", '-in', {EXIT=>2}, -- 2.47.3