1*34f9b3eeSRoland Mainz 2*34f9b3eeSRoland Mainz#### ksh93 test suite 3*34f9b3eeSRoland Mainz 4*34f9b3eeSRoland Mainz## Intro 5*34f9b3eeSRoland MainzThe directory /usr/demo/ksh/tests/ contains the ksh93 test suite 6*34f9b3eeSRoland Mainzwhich is used to verify the correct behaviour of ksh93. 7*34f9b3eeSRoland Mainz 8*34f9b3eeSRoland MainzThe test suite is split into modules with the ending *.sh 9*34f9b3eeSRoland Mainzand a frontend called "shtests" which is used to run the tests. 10*34f9b3eeSRoland Mainz 11*34f9b3eeSRoland Mainz 12*34f9b3eeSRoland Mainz## Basic description: 13*34f9b3eeSRoland Mainz/usr/demo/ksh/tests/shtests <options> <varname=value> <testmodule> 14*34f9b3eeSRoland Mainz 15*34f9b3eeSRoland Mainz<options> may be: 16*34f9b3eeSRoland Mainz -a execute test module one time as normal script code 17*34f9b3eeSRoland Mainz and a 2nd time as compiled shell script. The env 18*34f9b3eeSRoland Mainz variable SHCOMP defines the version of the shell 19*34f9b3eeSRoland Mainz compiler being used (default is "${SHELL%/*}/shcomp", 20*34f9b3eeSRoland Mainz however it is recommended to explicitly set SHCOMP 21*34f9b3eeSRoland Mainz to /usr/bin/shcomp). 22*34f9b3eeSRoland Mainz -c execute test module as compiled shell script 23*34f9b3eeSRoland Mainz -s execute test module as normal shell script 24*34f9b3eeSRoland Mainz -t do not print timing information 25*34f9b3eeSRoland Mainz -v use VMDEBUG 26*34f9b3eeSRoland Mainz<varname=value> 27*34f9b3eeSRoland Mainz Sets one or more environment variables to value "value". 28*34f9b3eeSRoland Mainz<testmodule> 29*34f9b3eeSRoland Mainz file name of test module 30*34f9b3eeSRoland Mainz 31*34f9b3eeSRoland Mainz 32*34f9b3eeSRoland Mainz## Basic usage in Solaris >= 11 and OpenSolaris/Indiana: 33*34f9b3eeSRoland MainzThe tests can be executed like this: 34*34f9b3eeSRoland Mainz$ export SHELL=<path-to-ksh93-executable> 35*34f9b3eeSRoland Mainz$ export SHCOMP=/usr/bin/shcomp 36*34f9b3eeSRoland Mainzfor t in /usr/demo/ksh/tests/*.sh ; do 37*34f9b3eeSRoland Mainz $SHELL /usr/demo/ksh/tests/shtests -a "$t" 38*34f9b3eeSRoland Mainzdone 39*34f9b3eeSRoland Mainz 40*34f9b3eeSRoland MainzNote that you MUST NOT use "/usr/bin/ksh93" as value for 41*34f9b3eeSRoland MainzSHELL since /usr/bin/ksh93 on Solaris is a wrapper which 42*34f9b3eeSRoland Mainzselects a suitable executable in /usr/bin/<isa>/ksh93 43*34f9b3eeSRoland Mainzbased on the hardware capabilities defined via /usr/bin/isalist 44*34f9b3eeSRoland Mainz 45*34f9b3eeSRoland MainzValid values for SHELL are: 46*34f9b3eeSRoland Mainz- SHELL=/usr/bin/i86/ksh93 # 32bit i386 47*34f9b3eeSRoland Mainz- SHELL=/usr/bin/amd64/ksh93 # 64bit AMD64 48*34f9b3eeSRoland Mainz- SHELL=/usr/bin/sparcv7/ksh93 # 32bit SPARC 49*34f9b3eeSRoland Mainz- SHELL=/usr/bin/sparcv9/ksh93 # 64bit SPARC 50*34f9b3eeSRoland Mainz- SHELL=/usr/bin/s390/ksh93 # 32bit SystemZ 51*34f9b3eeSRoland Mainz- SHELL=/usr/bin/s390x/ksh93 # 64bit SystemZ 52*34f9b3eeSRoland Mainz 53*34f9b3eeSRoland Mainz# EOF. 54