diff --git a/tests/stat/stat-printf.pl b/tests/stat/stat-printf.pl index 52206aa23..4f02df6ee 100755 --- a/tests/stat/stat-printf.pl +++ b/tests/stat/stat-printf.pl @@ -67,6 +67,10 @@ my @Tests = # and --format adds no trailing newline when it stops early. ['err-6', "--format=a%9 .", {OUT=>"a"}, {EXIT => 1}, {ERR=>"$prog: '%9': invalid directive\n"}], + + # The last of --printf and --format wins. + ['format-last', "--printf=X --format=Y .", {OUT=>"Y\n"}], + ['printf-last', "--format=Y --printf=X .", {OUT=>"X"}], ); my $save_temps = $ENV{DEBUG};