bootrr: emulate lava-test-case command

In case lava-test-command is not available, emulate what it is
supposed to do. This is a convenient hack to make it easier to run
bootrr locally for debug/testing purpose.

Signed-off-by: Nicolas Dechesne <nicolas.dechesne@linaro.org>
This commit is contained in:
Nicolas Dechesne
2018-06-13 17:09:43 +02:00
committed by Bjorn Andersson
parent 45640e5b26
commit 8db9a55c02

View File

@@ -15,7 +15,12 @@ timeout() {
test_report_exit() {
TEST_RESULT=$1
lava-test-case ${TEST_CASE_ID} --result ${TEST_RESULT}
command -v lava-test-case
if [ "$?" -eq 0 ]; then
lava-test-case ${TEST_CASE_ID} --result ${TEST_RESULT}
else
echo "<LAVA_SIGNAL_TESTCASE TEST_CASE_ID=${TEST_CASE_ID} RESULT=${TEST_RESULT}>"
fi
exit 0
}