Imported Upstream version 4.5.14
[platform/upstream/findutils.git] / find / testsuite / find.gnu / access.exp
1 # tests for -readable, -writable, -executable
2 exec rm -rf tmp
3 exec mkdir tmp
4 if { ! [ fs_superuser ] } {
5     touch tmp/x tmp/w tmp/r tmp/rw tmp/rwx tmp/0
6     exec chmod 400 tmp/r
7     exec chmod 200 tmp/w
8     exec chmod 100 tmp/x
9     exec chmod 000 tmp/0
10     exec chmod 600 tmp/rw
11     exec chmod 700 tmp/rwx
12     find_start p {tmp -readable -printf "r %p\n" , -writable -printf "w %p\n" , -executable  -printf "x %p\n"}
13     exec rm -rf tmp
14 }