pmrep: update TODO, man page
[pcp.git] / qa / 228
blob7968d098704f61083c9d421662c5ba888c5a672e
1 #! /bin/sh
2 # PCP QA Test No. 228
3 # pmie macro name handling in lexical scanner
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
15 status=1
16 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
18 _filter()
20 _show_pmie_errors \
21 | sed -e '/warning cannot create stats file dir/d'
24 # real QA test starts here
25 echo "special chars in macro name ..."
26 cat >$tmp.conf <<'End-of-File'
27 f_o_o_ = "sample";
28 foo = "sample";
29 'f!o!o' = "sample";
31 x = $foo.long.ten;
32 y = $f_o_o_.long.ten;
33 z = $'f!o!o'.long.ten;
34 End-of-File
35 pmie -v -t 1 -T 1 <$tmp.conf >$tmp.out 2>$tmp.err
36 cat $tmp.out $tmp.err | _filter
38 echo
39 echo "some syntax errors ..."
41 cat >$tmp.conf <<'End-of-File'
42 // $foo-not-bar not defined
43 x = $'foo-not-bar'.long.ten;
44 End-of-File
45 pmie -v -t 1 -T 1 <$tmp.conf >$tmp.out 2>$tmp.err
46 cat $tmp.out $tmp.err | _filter
48 cat >$tmp.conf <<'End-of-File'
49 // $foo not defined
50 x = $foo
51 End-of-File
52 pmie -v -t 1 -T 1 <$tmp.conf >$tmp.out 2>$tmp.err
53 cat $tmp.out $tmp.err | _filter
55 cat >$tmp.conf <<'End-of-File'
56 // e-o-f before end of macro name
57 x = $'foo-not-bar
58 End-of-File
59 pmie -v -t 1 -T 1 <$tmp.conf >$tmp.out 2>$tmp.err
60 cat $tmp.out $tmp.err | _filter
62 cat >$tmp.conf <<'End-of-File'
63 // macro name way too long
64 x = $'foo.long.ten.this.is.some.long.and.boring.text.to.make.the.macro.name.exceed.the.250-odd.char.limit.this.is.some.long.and.boring.text.to.make.the.macro.name.exceed.the.250-odd.char.limit.this.is.some.long.and.boring.text.to.make.the.macro.name.exceed.the.250-odd.char.limit';
65 End-of-File
66 pmie -v -t 1 -T 1 <$tmp.conf >$tmp.out 2>$tmp.err
67 cat $tmp.out $tmp.err | _filter
69 # all done
70 status=0
71 exit