Drop unused condition check
[pcp.git] / qa / 358
blobe7340eee5df42d0d0c7f060d511987e69e7f7809
1 #!/bin/sh
2 # PCP QA Test No. 358
4 # pmie fails for metric with instance domain containing one instance
5 # ... also some string constant exercises for embedded escapes
7 # Copyright (c) 2010 Ken McDonell. All Rights Reserved.
10 seq=`basename $0`
11 echo "QA output created by $seq"
13 # get standard environment, filters and checks
14 . ./common.product
15 . ./common.filter
16 . ./common.check
18 status=0 # success is the default!
19 $sudo rm -rf $tmp.* $seq.full
20 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
22 cat >$tmp.pmie <<'End-of-File'
23 some_inst ( match_inst "d" sample.dodgey.value > 0) -> print "short match ..." " [%i] %v";
24 some_inst ( match_inst "^d[12345]\$" sample.dodgey.value > 0) -> print "long match ..." " [%i] %v" "\t\"\\\$\\\" A\BC\(\)[]\78\9";
25 End-of-File
27 _filter()
29 tee -a $seq.full \
30 | sed -e 's/.* Info: evaluator exiting/pmie: note - evaluator exiting/g' \
31 -e 's/[A-Z][a-z][a-z] [A-Z][a-z][a-z] *[0-9][0-9]* [0-9][0-9]:[0-9][0-9]:[0-9][0-9] [0-9][0-9][0-9][0-9]/DATE/' \
32 -e 's/ [0-9][0-9]*/ NN/g' \
33 | LC_COLLATE=POSIX sort \
34 | uniq
37 # real QA test starts here
38 # for i in 5 2 1
39 for i in 1 2 5
41 echo "=== $i values for sample.dodgey.value ==="
42 pmstore sample.dodgey.control $i >/dev/null
43 pminfo -f sample.dodgey.value >>$seq.full
44 pmie -t 0.5 -T 2.3 <$tmp.pmie 2>&1 | _filter
45 done
47 pmstore sample.dodgey.control 5 >/dev/null
49 # success, all done
50 exit