r3180: - basic support for SEC_RIGHT_MAXIMUM_ALLOWED in pvfs
[gd/samba-autobuild/.git] / source4 / script / tests / test_posix.sh
1 #!/bin/sh
2
3 # this runs the file serving tests that are expected to pass with the
4 # current posix ntvfs backend
5
6 if [ $# -lt 3 ]; then
7 cat <<EOF
8 Usage: test_posix.sh UNC USERNAME PASSWORD <first>
9 EOF
10 exit 1;
11 fi
12
13 unc="$1"
14 username="$2"
15 password="$3"
16 start="$4"
17 shift 3
18
19 testit() {
20    cmdline="$*"
21    if ! $cmdline > test.$$ 2>&1; then
22        cat test.$$;
23        rm -f test.$$;
24        echo "TEST FAILED - $cmdline";
25        exit 1;
26    fi
27    rm -f test.$$;
28 }
29
30
31 tests="BASE-FDPASS BASE-LOCK1 BASE-LOCK2 BASE-LOCK3 BASE-LOCK4"
32 tests="$tests BASE-LOCK5 BASE-LOCK6 BASE-LOCK7 BASE-UNLINK BASE-ATTR"
33 tests="$tests BASE-TRANS2 BASE-NEGNOWAIT BASE-DIR"
34 tests="$tests BASE-DENY2 BASE-TCON BASE-TCONDEV BASE-RW1"
35 tests="$tests BASE-DENY3 BASE-XCOPY"
36 tests="$tests BASE-DELETE BASE-PROPERTIES BASE-MANGLE"
37 tests="$tests BASE-CHKPATH BASE-SECLEAK"
38 tests="$tests RAW-QFSINFO RAW-QFILEINFO RAW-SFILEINFO-BUG"
39 tests="$tests RAW-LOCK RAW-SEEK RAW-CONTEXT"
40
41
42 soon="BASE-DIR1 BASE-DENY1 BASE-VUID BASE-OPEN BASE-DEFER_OPEN BASE-RENAME BASE-OPENATTR BASE-CHARSET"
43 soon="$soon RAW-SFILEINFO RAW-SEARCH RAW-OPEN RAW-MKDIR RAW-OPLOCK RAW-NOTIFY RAW-MUX RAW-IOCTL"
44 soon="$soon RAW-CHKPATH RAW-UNLINK RAW-READ RAW-WRITE RAW-RENAME RAW-CLOSE"
45
46 for t in $tests; do
47     if [ ! -z "$start" -a "$start" != $t ]; then
48         continue;
49     fi
50     start=""
51     echo Testing $t
52     testit bin/smbtorture $unc -U"$username"%"$password" $t
53 done