mirror of
https://github.com/A2osX/A2osX.git
synced 2024-11-29 17:50:18 +00:00
88 lines
1.4 KiB
Plaintext
88 lines
1.4 KiB
Plaintext
#!/BIN/SHELL
|
|
ECHO "\f IF Numeric Tests
|
|
ECHO "\n This Performs Several Numeric Comparison Tests
|
|
ECHO -N "\nTest 1: 99 = 99 "
|
|
IF [ 99 -eq 99 ]
|
|
echo True Pass
|
|
ELSE
|
|
echo False Fail
|
|
FI
|
|
ECHO -N "Test 2: 99 = 79 "
|
|
IF [ 99 -eq 79 ]
|
|
echo True Fail
|
|
ELSE
|
|
echo False Pass
|
|
FI
|
|
ECHO -N "Test 3: 99 <> 99 "
|
|
IF [ 99 -NE 99 ]
|
|
echo True Fail
|
|
ELSE
|
|
echo False Pass
|
|
FI
|
|
ECHO -N "Test 4: 99 <> 79 "
|
|
IF [ 99 -NE 79 ]
|
|
echo True Pass
|
|
ELSE
|
|
echo False Fail
|
|
FI
|
|
ECHO -N "Test 5: 99 < 79 "
|
|
IF [ 99 -LT 79 ]
|
|
ECHO True Fail
|
|
ELSE
|
|
ECHO False Pass
|
|
FI
|
|
ECHO -N "Test 6: 79 < 99 "
|
|
IF [ 79 -LT 99 ]
|
|
ECHO True Pass
|
|
ELSE
|
|
ECHO False Fail
|
|
FI
|
|
ECHO -N "Test 7: 99 <= 79 "
|
|
IF [ 99 -LE 79 ]
|
|
ECHO True Fail
|
|
ELSE
|
|
ECHO False Pass
|
|
FI
|
|
ECHO -N "Test 8: 79 <= 99 "
|
|
IF [ 79 -LE 99 ]
|
|
ECHO True Pass
|
|
ELSE
|
|
ECHO False Fail
|
|
FI
|
|
ECHO -N "Test 9: 99 <= 99 "
|
|
IF [ 99 -LE 99 ]
|
|
ECHO True Pass
|
|
ELSE
|
|
ECHO False Fail
|
|
FI
|
|
ECHO -N "Test 10: 99 > 79 "
|
|
IF [ 99 -GT 79 ]
|
|
ECHO True Pass
|
|
ELSE
|
|
ECHO False Fail
|
|
FI
|
|
ECHO -N "Test 11: 79 > 99 "
|
|
IF [ 79 -GT 99 ]
|
|
ECHO True Fail
|
|
ELSE
|
|
ECHO False Pass
|
|
FI
|
|
ECHO -N "Test 12: 99 => 79 "
|
|
IF [ 99 -GE 79 ]
|
|
ECHO True Pass
|
|
ELSE
|
|
ECHO False Fail
|
|
FI
|
|
ECHO -N "Test 13: 79 => 99 "
|
|
IF [ 79 -GE 99 ]
|
|
ECHO True Fail
|
|
ELSE
|
|
ECHO False Pass
|
|
FI
|
|
ECHO -N "Test 14: 99 => 99 "
|
|
IF [ 99 -GE 99 ]
|
|
ECHO True Pass
|
|
ELSE
|
|
ECHO False Fail
|
|
FI
|
|
ECHO "\nEnd of Tests |