summaryrefslogtreecommitdiff
path: root/tests/general/Test-icon
diff options
context:
space:
mode:
Diffstat (limited to 'tests/general/Test-icon')
-rwxr-xr-xtests/general/Test-icon35
1 files changed, 18 insertions, 17 deletions
diff --git a/tests/general/Test-icon b/tests/general/Test-icon
index 07ccb87..9c3b265 100755
--- a/tests/general/Test-icon
+++ b/tests/general/Test-icon
@@ -1,36 +1,37 @@
#!/bin/sh
#
-# Test-icont -- test the Icon translator and interpreter.
+# Test-icon -- test the Icon translator and interpreter.
#
-# usage: Test-icont [file...]
-#
-# If $IC is set to iconc, the compiler will be used instead.
+# usage: Test-icon [BLKSIZE [STRSIZE]] [file...]
-IC=${IC-icont}
-IC=../../bin/$IC
+IC=../../bin/icont
ICONX=../../bin/iconx
unset IPATH LPATH FPATH
unset BLKSIZE STRSIZE MSTKSIZE COEXPSIZE QLSIZE
-# may be needed with Icon is built with BinaryHeader defined
+# may be needed if Icon is built with BinaryHeader defined
export ICONX
+# check for BKLSIZE / STRSIZE arguments
+case X$1 in
+ X[0-9]*) export BLKSIZE=$1; echo BLKSIZE=$1; shift;;
+esac
+case X$1 in
+ X[0-9]*) export STRSIZE=$1; echo STRSIZE=$1; shift;;
+esac
+
# echo system environment
echo ""
uname -a
# check that we have what we need
-case $IC in
- *icont)
- ls ../../bin/icont ../../bin/iconx >/dev/null || exit 0
- echo "icont: `$IC -V 2>&1`"
- echo "iconx: `$ICONX -V 2>&1`"
- ;;
- *iconc)
- ls -l ../../bin/iconc ../../bin/rt.* || exit 0
- ;;
-esac
+ls ../../bin/icont ../../bin/iconx >/dev/null || exit 0
+echo "icont: `$IC -V 2>&1`"
+echo "iconx: `$ICONX -V 2>&1`"
+
+# report enabled features
+$IC -s features.icn -x
# if no test files specified, run them all
if [ $# = 0 ]; then