cvsimport
[findutils.git] / find / testsuite / find.posix / perm-vanilla.exp
blobc6b551fa5baaa112582136467e0d382bed72cc79
1 # tests for -perm
2 exec rm -rf tmp
3 exec mkdir tmp
5 ## set up a selection of test files
6 foreach perm { 400 555 700 } {
7 touch "tmp/$perm"
8 exec chmod $perm "tmp/$perm"
10 exec ls -l tmp
13 # The -o operator normally has a short-circuit effect,
14 # so we have to use "-exec false \;" to make sure that
15 # all the parenthesised expression actually fail.
17 find_start p {tmp/400 tmp/555 tmp/700 \( -perm 400 -exec echo p400 \{\} \; -exec false \; \) -o \( -perm -400 -exec echo p-400 \{\} \; -exec false \; \) }
18 # exec rm -rf tmp tmp2