qt tools: update Mac OS X info files keys for highres displays
[pcp.git] / qa / 438
blob4fb3a453eff18ff0cc2e22fb268e8257309ad4ef
1 #!/bin/sh
2 # PCP QA Test No. 438
3 # Better code coverage for libpcp/src/logutil.c
5 # Copyright (c) 2010 Ken McDonell. All Rights Reserved.
8 seq=`basename $0`
9 echo "QA output created by $seq"
11 # get standard filters
12 . ./common.product
13 . ./common.filter
14 . ./common.check
16 status=0 # success is the default!
17 $sudo rm -rf $tmp.* $seq.full
18 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
20 # __pmLogChkLabel: fd=3 vol=0 [magic=50052602 version=2 vol=0 pid=3901 host=bozo]
21 # __pmLogSetTime(0) 17:29:20.472 delta=0 at ti[0]@17:29:20.472 vol=0 posn=132 serial=1
22 _filter()
24 sed \
25 -e 's/pid=[0-9][0-9]*/pid=PID/' \
26 -e 's/host=[a-zA-Z][a-zA-Z0-9_]*/host=HOST/' \
27 -e 's/[0-2][0-9]:[0-5][0-9]:[0-5][0-9]\.[0-9][0-9][0-9]/TIME/g' \
28 -e 's/TIME (t=[0-9][0-9.]*)/TIME/g' \
29 -e 's/bad trailer len=132/bad trailer len=0/' \
30 -e '/__pmLogChkLabel/s/fd=[0-9]/fd=N/' \
31 | $PCP_AWK_PROG '
32 $1 == "__pmLogOpen:" { print >"'$tmp'.0"; next }
33 { print >"'$tmp'.1" }'
34 LC_COLLATE=POSIX sort $tmp.0
35 cat $tmp.1
38 # real QA test starts here
39 for i in archives/badlen-*.0
41 [ "$i" = "archives/badlen-0.0" ] && continue
42 i=`echo $i | sed -e 's/\.0$//'`
43 echo | tee -a $seq.full
44 echo "--- $i ---" | tee -a $seq.full
45 pmdumplog -Dlog $i 2>&1 \
46 | tee -a $seq.full \
47 | _filter
48 done
50 # success, all done
51 exit