2 # make sure chown --from=... works
4 if test "$VERBOSE" = yes; then
9 . $srcdir/../envvar-check
10 . $srcdir/../lang-default
11 . $srcdir/../priv-check require-root
15 trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0
16 trap '(exit $?); exit' 1 2 13 15
19 mkdir $tmp || framework_failure=1
20 cd $tmp || framework_failure=1
21 touch f || framework_failure=1
23 if test $framework_failure = 1; then
24 echo 'failure in testing framework' 1>&2
31 # Make sure the owner and group are 0 and 1 respectively.
32 set _ `ls -n f`; shift; test "$3:$4" = 0:1 || fail=1
34 chown --from=0:1 2:3 f || fail=1
36 # And now they should be 2 and 3 respectively.
37 set _ `ls -n f`; shift; test "$3:$4" = 2:3 || fail=1