added tests

This commit is contained in:
ALEXks
2024-05-02 17:08:55 +03:00
parent d0d629eeb8
commit 94570a414b
431 changed files with 248194 additions and 1 deletions

View File

@@ -0,0 +1,26 @@
#!/bin/sh
# Requires variables: LAUNCH_EXIT_CODE, STDERR_FN
# Produces variables: TEST_PASSED, RESULT_COMMENT, ERROR_LEVEL
if [ `grep -E 'Assertion' <"$STDERR_FN" | wc -l` -gt 0 ]; then
TEST_PASSED=0
RESULT_COMMENT="Assertion failed"
ERROR_LEVEL=3
elif [ `grep -E 'RTS fatal' <"$STDERR_FN" | wc -l` -gt 0 ]; then
TEST_PASSED=0
RESULT_COMMENT="RTS fatal"
ERROR_LEVEL=2
elif [ `grep -E 'RTS err' <"$STDERR_FN" | wc -l` -gt 0 ]; then
TEST_PASSED=0
RESULT_COMMENT="RTS err"
ERROR_LEVEL=1
elif [ $LAUNCH_EXIT_CODE -ne 0 ]; then
TEST_PASSED=0
RESULT_COMMENT="Launch failure"
ERROR_LEVEL=4
else
TEST_PASSED=1
RESULT_COMMENT="OK"
ERROR_LEVEL=0
fi