]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
tests: split: ensure directories not replaced
authoroech3 <79379754+oech3@users.noreply.github.com>
Thu, 1 Jan 2026 16:03:41 +0000 (01:03 +0900)
committerPádraig Brady <P@draigBrady.com>
Sat, 3 Jan 2026 14:27:55 +0000 (14:27 +0000)
* tests/split/split-io-err.sh: Add a test case.
From https://github.com/coreutils/coreutils/pull/158

tests/split/split-io-err.sh

index a1faae4bcb47f748b6ab5628a04771718ae44094..3eb9dbb93f0b92d032acc5b784443c1db7384c21 100755 (executable)
@@ -38,4 +38,10 @@ test -e xab && fail=1
 # Ensure we got the expected error message
 compare exp err || fail=1
 
+rm xaa || framework_failure_
+# Similar for directory
+mkdir xaa || framework_failure_
+seq 2 | returns_ 1 split -b 1 2 || fail=1
+test -d xaa || fail=1
+
 Exit $fail