Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fv3atm cap cleanup #954

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Weekly test (#17)
* modify rt.sh, rt_utils.sh and run_test.sh for weekly_test
  • Loading branch information
binli2337 authored Dec 16, 2021
commit f9bc4e707be4e85e4127734e4c09bbcbd7e72088
15 changes: 12 additions & 3 deletions tests/rt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ die() { echo "$@" >&2; exit 1; }
usage() {
set +x
echo
echo "Usage: $0 -c | -e | -h | -k | -l <file> | -m | -n <name> | -r "
echo "Usage: $0 -c | -e | -h | -k | -w | -l <file> | -m | -n <name> | -r "
echo
echo " -c create new baseline results"
echo " -e use ecFlow workflow manager"
Expand All @@ -19,6 +19,7 @@ usage() {
echo " -m compare against new baseline results"
echo " -n run single test <name>"
echo " -r use Rocoto workflow manager"
echo " -w for weekly_test, skip comparing baseline results"
echo
set -x
exit 1
Expand Down Expand Up @@ -407,10 +408,11 @@ ECFLOW=false
KEEP_RUNDIR=false
SINGLE_NAME=''
TEST_35D=false
export skip_check_results=false

TESTS_FILE='rt.conf'

while getopts ":cl:mn:kreh" opt; do
while getopts ":cl:mn:wkreh" opt; do
case $opt in
c)
CREATE_BASELINE=true
Expand All @@ -427,6 +429,9 @@ while getopts ":cl:mn:kreh" opt; do
TESTS_FILE='rt.conf.single'
rm -f $TESTS_FILE
;;
w)
export skip_check_results=true
;;
k)
KEEP_RUNDIR=true
;;
Expand Down Expand Up @@ -482,7 +487,11 @@ if [[ $CREATE_BASELINE == true ]]; then
mkdir -p "${NEW_BASELINE}"
fi

REGRESSIONTEST_LOG=${PATHRT}/RegressionTests_$MACHINE_ID.log
if [[ $skip_check_results == true ]]; then
REGRESSIONTEST_LOG=${PATHRT}/RegressionTests_weekly_$MACHINE_ID.log
else
REGRESSIONTEST_LOG=${PATHRT}/RegressionTests_$MACHINE_ID.log
fi

date > ${REGRESSIONTEST_LOG}
echo "Start Regression test" >> ${REGRESSIONTEST_LOG}
Expand Down
8 changes: 7 additions & 1 deletion tests/rt_utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ submit_and_wait() {

if [[ $test_status = 'FAIL' ]]; then
if [[ ${OPNREQ_TEST} == false ]]; then
echo "${TEST_NAME} ${TEST_NR} failed" >> $PATHRT/fail_test_${TEST_NR}
echo "${TEST_NAME} ${TEST_NR}" >> $PATHRT/fail_test_${TEST_NR}
echo "Test ${TEST_NR} ${TEST_NAME} FAIL" >> ${REGRESSIONTEST_LOG}
echo;echo;echo >> ${REGRESSIONTEST_LOG}
echo "Test ${TEST_NR} ${TEST_NAME} FAIL"
Expand All @@ -215,6 +215,12 @@ submit_and_wait() {
fi
fi

if [[ $test_status = 'PASS' || $test_status = 'DONE' ]]; then
echo "Test ${TEST_NR} ${TEST_NAME} RUN_SUCCESS" >> ${REGRESSIONTEST_LOG}
echo;echo;echo >> ${REGRESSIONTEST_LOG}
echo "Test ${TEST_NR} ${TEST_NAME} RUN_SUCCESS"
fi

eval "$set_x"
}

Expand Down
4 changes: 3 additions & 1 deletion tests/run_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,9 @@ else

fi

check_results
if [[ $skip_check_results = false ]]; then
check_results
fi

if [[ $SCHEDULER != 'none' ]]; then
cat ${RUNDIR}/job_timestamp.txt >> ${LOG_DIR}/job_${JOB_NR}_timestamp.txt
Expand Down