qa: update 660 to generate index.html, fixing pcp-testsuite runs
[pcp.git] / qa / 328
blob062fd8df60700534af4f3e48bd540df6fece8ab7
1 #! /bin/sh
2 # PCP QA Test No. 328
3 # pmlogextract grok new archives with embedded <mark>s
5 # Copyright (c) 1995-2002 Silicon Graphics, Inc. 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=1 # failure is the default!
17 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
19 _check()
21 echo
22 pmdumplog -z $tmp 2>&1 | grep '<mark>' >$tmp.merge
23 cat $tmp.one $tmp.other \
24 | diff -c - $tmp.merge \
25 | sed \
26 -e 's/^\*\*\* Standard .*/*** concatenated from input archives/' \
27 -e 's/^\*\*\* -.*/*** concatenated from input archives/' \
28 -e 's/^--- \/.*/--- merged archive/'
31 # deal with an annoying libc error ... using TZ=:Australia/Melbourne
32 # causes the -z option to report the wrong time, at least for some
33 # times of the year
35 TZ=EST-10
36 export TZ
38 # real QA test starts here
40 echo
41 echo 'marks in one archive ...'
42 pmdumplog -z archives/19970807.09.54 2>&1 | grep '<mark>' >$tmp.one
43 cat $tmp.one
45 echo
46 echo 'marks in other archive ...'
47 pmdumplog -z archives/19970807.09.59 2>&1 | grep '<mark>' >$tmp.other
48 cat $tmp.other
50 echo
51 echo 'pmlogextract ... and marks ... and diffs (expect an extra one in the middle)'
52 pmlogextract archives/19970807.09.54 archives/19970807.09.59 $tmp
53 _check
55 echo
56 echo 'pmlogextract ... and marks ... and diffs (expect an extra one in the middle)'
57 rm -f $tmp.0 $tmp.meta $tmp.index
58 pmlogextract archives/19970807.09.54 archives/19970807.09.59 $tmp
59 _check
61 # success, all done
62 status=0
63 exit