Skip to content

Commit

Permalink
A bit more automation and cleanup for run_tests
Browse files Browse the repository at this point in the history
git-svn-id: file:///home/users/tmap/svn/repos/ferret/trunk@23962 fdbf22ae-c210-0410-be80-ca943da6b8f8
  • Loading branch information
karlmsmith committed Jul 6, 2017
1 parent c42652a commit 7924367
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
16 changes: 10 additions & 6 deletions bench/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Makefile for the FERRET/bench directory
# Makefile for the Ferret bench subdirectory
#

# include platform specific macro definitions for make_stream_file
Expand All @@ -14,7 +14,7 @@ run_tests:
exit 1 ; \
fi
./RUN_TESTS.sh `which ferret` "$(FER_EXTERNAL_FUNCTIONS)"
@echo 'Differences in the generated bench/*.gif files versus against those in bench/test_results'
@echo 'Differences in the generated bench GIF files versus those in bench/test_results'
-@for img in *.gif ; \
do \
if diff -q $$img test_results/$$img ; then \
Expand All @@ -23,15 +23,19 @@ run_tests:
compare $$img test_results/$$img "$$img"_diff.gif ; \
fi \
done
-@( datetag=`date +'%d%h%yAT'|tr '[A-Z]' '[a-z]'` ; \
diff all_$${datetag}*_ncdump test_results/ferret_run_tests_ncdump 1> ferret_run_tests_ncdump.diff 2>&1 ; \
diff all_$${datetag}*_err test_results/ferret_run_tests_err 1> ferret_run_tests_err.diff 2>&1 ; \
diff all_$${datetag}*_log test_results/ferret_run_tests_log 1> ferret_run_tests_log.diff 2>&1 \
)
@echo ''
@echo 'Inspect the bench/all_*_ncdump, bench/all_*_err, and bench/all_*_log files just created '
@echo 'against bench/test_results/ferret_run_tests_ncdump, bench/test_results/ferret_run_test_err, '
@echo 'and bench/test_results/ferret_run_tests_log'
@echo 'Inspect the *_diff.gif files for actual differences in the images'
@echo 'Inspect the ferret_run_tests_*.diff files for actual differences in the output'

.PHONY: clean
clean:
rm -f all_*_ncdump all_*_err all_*_log all_*_ncdump_orig all_*_err_orig all_*_log_orig cleanups.sed
rm -f *.plt* *.gif* *.ps* *.png* *.pdf* ferret.jnl*
rm -f *.plt* *.gif* *.diff* ferret.jnl*
rm -f `cat TRASH_FILES`
rm -f all_ncdump.out fort.41 make_stream_file
rm -fr subdir tmp
Expand Down
3 changes: 3 additions & 0 deletions bench/RUN_TESTS.sh
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,9 @@ timeregex=`date +%-d.%h.%y`
echo "s/${timeregex}.[0-9][0-9]:[0-9][0-9]/DD-MON-YY HH:MM/g" >> $cleanups
echo "s/$timeregex/DD-MON-YY/g" >> $cleanups

timeregex=`date +%m.%d.%y`
echo "s/$timeregex/MM-DD-YY/g" >> $cleanups

timeregex=`date | sed -e 's/[0-9][0-9]:[0-9][0-9]:[0-9][0-9]/[0-9][0-9]:[0-9][0-9]:[0-9][0-9]/'`
echo "s/$timeregex/WKD MON DD HH:MM:SS ZZZ YYYY/g" >> $cleanups

Expand Down
2 changes: 1 addition & 1 deletion bench/test_results/ferret_run_tests_log
Original file line number Diff line number Diff line change
Expand Up @@ -62819,7 +62819,7 @@ list contents
SUBSET : 45 points (X)
1 / 1:" ! NOAA/PMEL TMAP"
2 / 2:" ! FERRET v7.13 (beta/debug)"
3 / 3:" ! Linux 3.10.0-514.26.2.el7.x86_64 64-bit - 07/06/17"
3 / 3:" ! Linux 3.10.0-514.26.2.el7.x86_64 64-bit - MM-DD-YY"
4 / 4:" ! DD-MON-YY HH:MM "
5 / 5:""
6 / 6:"! "
Expand Down

0 comments on commit 7924367

Please sign in to comment.