mars/test_suite/scripts/modules/main.sh
Frank Liepold e38d873564 test_suite: separation of frame work and use case mars
The mars test cases are now located in .../test_suite/mars.
The use case .../test_suite/example describes how the frame work works (please
refer to README).
mars_test_cronjob.sh have a second parameter which specifies the use case
directory (.../test_suite/mars).
The leading numbers in the module numbers are no longer needed.
2014-02-05 08:48:42 +01:00

45 lines
936 B
Bash

prepare_list=""
setup_list=""
run_list=""
cleanup_list=""
finish_list=""
function main
{
ok=1
main_start_time=$(date +'%Y%m%d%H%M%S')
for script in $prepare_list; do
if (( ok )); then
(( main_verbose_script )) && echo "calling $script"
$script || ok=0
fi
done
for script in $setup_list; do
if (( ok )); then
(( main_verbose_script )) && echo "calling $script"
$script || ok=0
fi
done
for script in $run_list; do
if (( ok )); then
(( main_verbose_script )) && echo "calling $script"
$script || ok=0
fi
done
for script in $cleanup_list; do
(( main_verbose_script )) && echo "calling $script"
$script
done
for script in $finish_list; do
(( main_verbose_script )) && echo "calling $script"
$script
done
return $(( !ok ))
}
function main_test_no_longer_in_use
{
echo "This test is kept only for historical reasons and does not run anymore"
}