From 1bab8760068a4a45396780d6f85902a8d07ade89 Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Mon, 8 Sep 2025 14:02:15 -0500 Subject: [PATCH] Add test for write falure. --- tests/cp.test | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/cp.test b/tests/cp.test index 3e25f6c6..1ffd3cae 100755 --- a/tests/cp.test +++ b/tests/cp.test @@ -56,9 +56,13 @@ testing "file->inaccessible_dir [fail]" \ rm two rmdir sub +echo thingy > file +testcmd 'write failure' 'file /dev/full 2>/dev/null || echo yes' 'yes\n' '' '' +rm -f file + # This test fails because our -rf deletes existing target files without # regard to what we'd be copying over it. Posix says to only do that if -# we'd be copying a file over the file, but does not say _why_. +# we'd be copying a file over the file, but does not say _why_. TODO #mkdir dir #touch file -- 2.39.5