python api: fix syntax error in recent context changes
[pcp.git] / qa / 219
blob47fe2d5831a6813c29947da14db34283e5654545
1 #! /bin/sh
2 # PCP QA Test No. 219
3 # check pmdbg -l and pmdbg.h agree
5 # Copyright (c) 2009 Silicon Graphics, Inc. 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 if [ -f $PCP_INC_DIR/pmdbg.h ]
17 then
19 else
20 echo "$PCP_INC_DIR/pmdbg.h not installed?" >$seq.notrun
21 echo "$seq: [not run] `cat $seq.notrun`"
22 exit 0
25 status=0 # success is the default!
26 $sudo rm -rf $tmp.*
27 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
29 # real QA test starts here
30 pmdbg -l \
31 | tee $seq.full \
32 | sed -n -e '/^DBG_/s/[ ].*//p' \
33 | LC_COLLATE=POSIX sort >$tmp.dbg
35 echo "------" >>$seq.full
36 cat $PCP_INC_DIR/pmdbg.h >>$seq.full
37 sed -n <$PCP_INC_DIR/pmdbg.h \
38 -e '/DBG_/{
39 s/.*DBG_/DBG_/
40 s/[ ].*//
42 }' \
43 | LC_COLLATE=POSIX sort >$tmp.dbg.h
45 echo "Missing from pmdbg -l ..."
46 comm -23 $tmp.dbg.h $tmp.dbg
48 echo
49 echo "Missing from <pcp/pmdbg.h> ..."
50 comm -13 $tmp.dbg.h $tmp.dbg
52 # success, all done
53 exit