]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
tests: avoid false failure sync'ing busy systems
authorPádraig Brady <P@draigBrady.com>
Mon, 2 Feb 2026 11:54:02 +0000 (11:54 +0000)
committerPádraig Brady <P@draigBrady.com>
Mon, 2 Feb 2026 12:55:37 +0000 (12:55 +0000)
* tests/misc/sync.sh: Increase the timeout to 60s,
and restrict the case to when RUN_VERY_EXPENSIVE_TESTS=yes.

tests/misc/sync.sh

index fa2ca86fa6a8470e850107269f49474aed667181..f782a2b9a1d1f033bb38db515e50438de30707b1 100755 (executable)
@@ -61,8 +61,12 @@ if test "$fail" != '1'; then
   # Ensure a fifo doesn't block
   mkfifo_or_skip_ fifo
   for opt in '' '-f' '-d'; do
-    test "$opt" = '-f' && test "$RUN_EXPENSIVE_TESTS" != yes && continue
-    returns_ 124 timeout 10 sync $opt fifo && fail=1
+    timeout=10
+    if test "$opt" = '-f'; then
+      test "$RUN_VERY_EXPENSIVE_TESTS" = yes || continue
+      timeout=60
+    fi
+    returns_ 124 timeout "$timeout" sync $opt fifo && fail=1
   done
 fi