qa: update 660 to generate index.html, fixing pcp-testsuite runs
[pcp.git] / qa / 838
blobd549a644ec24b2dd0453a5a85033c2dc94c2fb79
1 #!/bin/sh
2 # PCP QA Test No. 838
3 # Check that -d option (duplicate are OK in the PMNS) is deprecated
5 # Copyright (c) 2015 Ken McDonell. All Rights Reserved.
8 seq=`basename $0`
9 echo "QA output created by $seq"
11 # get standard environment, filters and checks
12 . ./common.product
13 . ./common.filter
14 . ./common.check
16 status=1 # failure is the default!
17 $sudo rm -rf $tmp.* $seq.full
18 trap "cd $here; rm -rf $tmp.*; exit \$status" 0 1 2 3 15
20 _filter()
22 sed \
23 -e '/Operation not permitted/d' \
24 -e '/^ *$/d'
25 # end
29 mkdir $tmp.pmns
30 cd $tmp.pmns
32 cat <<End-of-File >root_one
33 root {
34 one
36 one {
37 foo 1:2:3
38 bar 1:4:5
40 End-of-File
42 cat <<End-of-File >two
43 two {
44 mumble 2:0:0
45 fumble 2:0:0 /* duplicate name */
47 End-of-File
49 # real QA test starts here
50 echo "=== Rebuild -d ==="
51 $PCP_VAR_DIR/pmns/Rebuild -d 2>&1 | _filter
52 pminfo -n root -m
54 echo
55 echo "=== pmnsadd -d ==="
56 pmnsadd -d -n root two
57 pminfo -n root -m
59 echo
60 echo "=== pmnsdel -d ==="
61 pmnsdel -d -n root one
62 pminfo -n root -m
64 echo
65 echo "=== pmnsmerge -d ==="
66 pmnsmerge -d root root_one root_new
67 pminfo -n root_new -m
69 # success, all done
70 status=0
72 exit