aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/gna/ticket24/testsuite.sh
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2016-03-18 05:26:29 +0100
committerTristan Gingold <tgingold@free.fr>2016-03-18 05:26:29 +0100
commitf5d6578a062f1af9c3508ed26b0f7edff04b1a01 (patch)
tree44e86f3ca64f25f0c59cc5ff5a7488673fbba631 /testsuite/gna/ticket24/testsuite.sh
parent1c8872240feffcc2324a1b46a055d5afcfa3e2bb (diff)
downloadghdl-f5d6578a062f1af9c3508ed26b0f7edff04b1a01.tar.gz
ghdl-f5d6578a062f1af9c3508ed26b0f7edff04b1a01.tar.bz2
ghdl-f5d6578a062f1af9c3508ed26b0f7edff04b1a01.zip
Add testcase for ticket24
Diffstat (limited to 'testsuite/gna/ticket24/testsuite.sh')
-rwxr-xr-xtestsuite/gna/ticket24/testsuite.sh24
1 files changed, 24 insertions, 0 deletions
diff --git a/testsuite/gna/ticket24/testsuite.sh b/testsuite/gna/ticket24/testsuite.sh
new file mode 100755
index 000000000..96b37c948
--- /dev/null
+++ b/testsuite/gna/ticket24/testsuite.sh
@@ -0,0 +1,24 @@
+#! /bin/sh
+
+. ../../testenv.sh
+
+analyze -fpsl psl.vhdl
+elab_simulate -fpsl psl --psl-report=psl.out
+
+if ! cmp psl.out psl.ref; then
+ echo "report mismatch"
+ exit 1
+fi
+
+# Usage example (python 2.7):
+#
+# import json
+# d=json.load(open("psl.out"))
+# print d['summary']
+# {u'assert-pass': 2, u'cover': 1, ... }
+# print d['summary']['assert']
+
+rm -f psl.out
+clean
+
+echo "Test successful"