summaryrefslogtreecommitdiff
path: root/qa/021
diff options
context:
space:
mode:
Diffstat (limited to 'qa/021')
-rwxr-xr-xqa/02156
1 files changed, 56 insertions, 0 deletions
diff --git a/qa/021 b/qa/021
new file mode 100755
index 0000000..44e8a5e
--- /dev/null
+++ b/qa/021
@@ -0,0 +1,56 @@
+#! /bin/sh
+# PCP QA Test No. 021
+# test pmgenmap handling of comments
+#
+# Copyright (c) 1995-2002 Silicon Graphics, Inc. All Rights Reserved.
+#
+
+_strip()
+{
+ $PCP_AWK_PROG '
+/Built/ { print; name = 1; next }
+name == 1 { print "<filename goes in here>"; name = 0; date = 1; next }
+date == 1 { print "<date goes in here>"; date = 0; next }
+ { print }'
+}
+
+seq=`basename $0`
+echo "QA output created by $seq"
+
+# get standard filters
+. ./common.product
+. ./common.filter
+
+trap "rm -f $tmp.*; exit 0" 0 1 2 3 15
+
+# real QA test starts here
+cat <<End-of-File >$tmp.spec
+# leading single line comment
+foo {
+ a.b.c ONE
+ d.e.f.g TWO
+ # embedded single line comment
+ xx.yy.zz THREE
+}
+# trailing block of
+# multi-lines
+# comments
+End-of-File
+
+pmgenmap $tmp.spec | _strip
+
+cat <<End-of-File >$tmp.spec
+# leading block of
+# multi-lines
+# comments
+foo {
+ a.b.c ONE
+ d.e.f.g TWO
+ # embedded block of multi-lines
+ # comments and boring pad text
+ xx.yy.zz THREE
+}
+# trailing single line comment
+End-of-File
+
+pmgenmap $tmp.spec | _strip