mirror of
https://github.com/A2osX/A2osX.git
synced 2024-11-23 07:35:19 +00:00
32 lines
773 B
Plaintext
32 lines
773 B
Plaintext
NEW
|
||
PREFIX /A2OSX.BUILD
|
||
AUTO 4,1
|
||
#!/BIN/SHELL
|
||
#
|
||
# BADSHTEST tests that the shell detects and properly handles
|
||
# (with error) an invalid shell script. It should return error
|
||
# F6/246. This script calls BADSCRIPT and checks for that code.
|
||
#
|
||
echo "\n\nThis test will generate an error"
|
||
echo "between the lines. This is expected."
|
||
echo "---------------------------------------"
|
||
BADSCRIPT
|
||
SET R = $?
|
||
ECHO $R
|
||
echo "---------------------------------------"
|
||
IF [ $R -EQ 246 ]
|
||
IF [ $B -GT 0 ]
|
||
SET P = $P + 1
|
||
echo "BADSHTEST Passed" >> ${Log}
|
||
FI
|
||
echo "\nBADSHTEST Passed\n"
|
||
ELSE
|
||
IF [ $B -GT 0 ]
|
||
SET F = $F + 1
|
||
echo "BADSHTEST Failed" >> ${Log}
|
||
FI
|
||
echo "\nBADSHTEST Failed\n"
|
||
FI
|
||
MAN
|
||
TEXT USR/SHARE/TESTS/BADSHTEST
|