aboutsummaryrefslogtreecommitdiff
path: root/testsuite/runtest.libs
diff options
context:
space:
mode:
authorJacob Bachmeyer <jcb62281+dev@gmail.com>2020-06-05 16:05:45 -0500
committerJacob Bachmeyer <jcb62281+dev@gmail.com>2020-06-05 16:05:45 -0500
commit5096a3c6208a392ea601466bb874a59fd51d95d2 (patch)
tree44844206770aa93bfba9a49f210a3c4765955b88 /testsuite/runtest.libs
parent5fafcd43b2d22b2227e62f7278584418c6449824 (diff)
downloaddejagnu-5096a3c6208a392ea601466bb874a59fd51d95d2.zip
dejagnu-5096a3c6208a392ea601466bb874a59fd51d95d2.tar.gz
dejagnu-5096a3c6208a392ea601466bb874a59fd51d95d2.tar.bz2
Add "testsuite can call api" feature test API
Diffstat (limited to 'testsuite/runtest.libs')
-rw-r--r--testsuite/runtest.libs/testsuite_can.test29
1 files changed, 29 insertions, 0 deletions
diff --git a/testsuite/runtest.libs/testsuite_can.test b/testsuite/runtest.libs/testsuite_can.test
new file mode 100644
index 0000000..98d4e38
--- /dev/null
+++ b/testsuite/runtest.libs/testsuite_can.test
@@ -0,0 +1,29 @@
+# test "testsuite can" API call -*- Tcl -*-
+
+if [ file exists $srcdir/$subdir/default_procs.tcl ] {
+ source "$srcdir/$subdir/default_procs.tcl"
+} else {
+ puts "ERROR: $srcdir/$subdir/default_procs.tcl doesn't exist"
+}
+if [ file exists $srcdir/../lib/framework.exp] {
+ source $srcdir/../lib/framework.exp
+} else {
+ puts "ERROR: $srcdir/../lib/framework.exp doesn't exist"
+}
+
+# API availability check tests
+
+run_tests {
+ { lib_errpat_test testsuite { can }
+ "*unknown feature test*"
+ "testsuite can without arguments" }
+ { lib_errpat_test testsuite { can call }
+ "*unknown feature test*"
+ "testsuite can call without 'api'" }
+ { lib_bool_test testsuite { can call api } false
+ "testsuite can call api returns false for null API call name" }
+ { lib_bool_test testsuite { can call api testsuite can call api } true
+ "testsuite can call api reports its own existence" }
+}
+
+puts "END testsuite_can.test"