From 083f89528ed77d91fd780c5fc81652aef319934b Mon Sep 17 00:00:00 2001 From: =?utf8?q?P=C3=A1draig=20Brady?=
Date: Sat, 12 Jul 2025 19:58:06 +0100 Subject: [PATCH] tests: sort: add a test for equivalent floats * tests/sort/sort-float.sh: Ensure equivalent floats are treated as such. --- tests/sort/sort-float.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/sort/sort-float.sh b/tests/sort/sort-float.sh index 433a21970..1439edd70 100755 --- a/tests/sort/sort-float.sh +++ b/tests/sort/sort-float.sh @@ -94,4 +94,7 @@ $LDBL_MAX compare exp out || fail=1 done +# Ensure equal floats are treated as such +test $(printf '%s\n' 10 1e1 | sort -gu | wc -l) = 1 || fail=1 + Exit $fail -- 2.39.5