Skip to content

Commit

Permalink
Fix compare_nc ufs-community#296
Browse files Browse the repository at this point in the history
  • Loading branch information
MinsukJi-NOAA committed Jan 26, 2021
1 parent 6b6d74f commit 6e9dfc7
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions tests/rt_utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -270,13 +270,19 @@ check_results() {

else

d=$( cmp ${RTPWD}/${CNTL_DIR}/$i ${RUNDIR}/$i | wc -l )
cmp ${RTPWD}/${CNTL_DIR}/$i ${RUNDIR}/$i >/dev/null 2>&1 && d=$? || d=$?
if [[ $d -eq 2 ]]; then
exit 1
fi

if [[ $d -ne 0 ]] ; then
if [[ $d -eq 1 ]] ; then
if [[ ${MACHINE_ID} =~ orion || ${MACHINE_ID} =~ hera || ${MACHINE_ID} =~ wcoss_dell_p3 || ${MACHINE_ID} =~ wcoss_cray || ${MACHINE_ID} =~ cheyenne || ${MACHINE_ID} =~ gaea || ${MACHINE_ID} =~ jet ]]; then
printf ".......ALT CHECK.." >> ${REGRESSIONTEST_LOG}
printf ".......ALT CHECK.."
d=$( ${PATHRT}/compare_ncfile.py ${RTPWD}/${CNTL_DIR}/$i ${RUNDIR}/$i 2>/dev/null | wc -l )
${PATHRT}/compare_ncfile.py {RTPWD}/${CNTL_DIR}/$i ${RUNDIR}/$i 1>/dev/null 2>&1 && d=$? || d=$?
if [[ $d -eq 1 ]]; then
exit 1
fi
fi
fi

Expand Down

0 comments on commit 6e9dfc7

Please sign in to comment.