du: already passes GNU test in spirit, adjust test

This commit is contained in:
Ben Wiederhake 2025-04-14 01:38:01 +02:00
parent c35d26dc51
commit 53836c9bd9
3 changed files with 18 additions and 1 deletions

View file

@ -8,3 +8,4 @@ tests_invalid_opt.patch
tests_ls_no_cap.patch
tests_sort_merge.pl.patch
tests_tsort.patch
tests_du_move_dir_while_traversing.patch

View file

@ -0,0 +1,16 @@
Index: gnu/tests/du/move-dir-while-traversing.sh
===================================================================
--- gnu.orig/tests/du/move-dir-while-traversing.sh
+++ gnu/tests/du/move-dir-while-traversing.sh
@@ -91,9 +91,7 @@ retry_delay_ nonempty .1 5 || fail=1
# Before coreutils-8.10, du would abort.
returns_ 1 du -a $t d2 2> err || fail=1
-# check for the new diagnostic
-printf "du: fts_read failed: $t/3/a/b: No such file or directory\n" > exp \
- || fail=1
-compare exp err || fail=1
+# check that it doesn't crash
+grep -Pq "^du: cannot read directory '$t/3/a/b.*': No such file or directory" err || fail=1
Exit $fail

View file

@ -2,7 +2,7 @@ Index: gnu/tests/env/env-S.pl
===================================================================
--- gnu.orig/tests/env/env-S.pl
+++ gnu/tests/env/env-S.pl
@@ -209,27 +209,28 @@ my @Tests =
@@ -212,27 +212,28 @@ my @Tests =
{ERR=>"$prog: no terminating quote in -S string\n"}],
['err5', q[-S'A=B\\q'], {EXIT=>125},
{ERR=>"$prog: invalid sequence '\\q' in -S\n"}],