mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2025-09-10 07:59:52 +02:00
mv: port test to OpenBSD 7.5
Problem reported by Bruno Haible <https://bugs.gnu.org/75685>. * tests/mv/sticky-to-xpart.sh: Also allow OpenBSD behavior.
This commit is contained in:
@@ -59,10 +59,19 @@ chroot --skip-chdir --user=$NON_ROOT_USERNAME / env PATH="$PATH" \
|
||||
onp='Operation not permitted'
|
||||
sed "s/Not owner/$onp/;s/Permission denied/$onp/" out-t > out
|
||||
|
||||
cat <<\EOF > exp
|
||||
mv: cannot remove 't/root-owned': Operation not permitted
|
||||
# On some systems (OpenBSD 7.5), the initial rename fails with EPERM,
|
||||
# which is arguably better than the Linux kernel's EXDEV.
|
||||
cat <<EOF >exp1 || framework_failure_
|
||||
mv: cannot move 't/root-owned' to '$other_partition_tmpdir/root-owned': $onp
|
||||
EOF
|
||||
|
||||
compare exp1 out >/dev/null || {
|
||||
|
||||
cat <<EOF >exp || framework_failure_
|
||||
mv: cannot remove 't/root-owned': $onp
|
||||
EOF
|
||||
|
||||
compare exp out || fail=1
|
||||
}
|
||||
|
||||
Exit $fail
|
||||
|
||||
Reference in New Issue
Block a user