]> git.cworth.org Git - notmuch/commitdiff
test: remove unnecessary sorting
authorKevin Boulain <kevin@boula.in>
Wed, 29 Mar 2023 16:13:30 +0000 (18:13 +0200)
committerDavid Bremner <david@tethera.net>
Thu, 30 Mar 2023 10:48:27 +0000 (07:48 -0300)
The other tests rely on a stable output.

test/T610-message-property.sh

index 07a480531534e62334276eb2c4848e4bf1b429fb..a4814d6445025f0b89b0fdb6c809daf3ebfd3d39 100755 (executable)
@@ -186,18 +186,6 @@ EXPECT0(notmuch_message_add_property (message, "testkey3", "testvalue3"));
 EXPECT0(notmuch_message_add_property (message, "testkey3", "alice3"));
 print_properties (message, "testkey", FALSE);
 EOF
-# expected: 4 values for testkey1, 3 values for testkey3
-# they are not guaranteed to be sorted, so sort them, leaving the first
-# line '== stdout ==' and the end ('== stderr ==' and whatever error
-# may have been printed) alone
-mv OUTPUT unsorted_OUTPUT
-awk ' NR == 1 { print; next } \
-      NR < 6  { print | "sort"; next } \
-      NR == 6 { close("sort") } \
-      NR < 9  { print | "sort"; next } \
-      NR == 9 { close("sort") } \
-      { print }' unsorted_OUTPUT > OUTPUT
-rm unsorted_OUTPUT
 cat <<'EOF' >EXPECTED
 == stdout ==
 testkey1 = alice