Testing: add env var to allow verbose output

This commit is contained in:
Shahram Najm 2015-01-26 17:26:18 +00:00
parent d3e0029c3b
commit 1fca46dfb4
6 changed files with 36 additions and 0 deletions

View File

@ -1,6 +1,12 @@
# examples/C include file for CMake
set -ea
# If this environment variable is set, then become verbose
# so one can see why and how a test failed
if test "x$ECCODES_TEST_VERBOSE_OUTPUT" != "x"; then
set -x
fi
proj_dir=@PROJECT_SOURCE_DIR@
data_dir=@PROJECT_BINARY_DIR@/data

View File

@ -17,6 +17,12 @@ else
echo
echo "TEST: $0"
# If this environment variable is set, then become verbose
# so one can see why and how a test failed
if test "x$ECCODES_TEST_VERBOSE_OUTPUT" != "x"; then
set -x
fi
if [ -z "${data_dir}" ]
then
cd ../../

View File

@ -1,6 +1,12 @@
# examples/F90 include file for CMake
set -ea
# If this environment variable is set, then become verbose
# so one can see why and how a test failed
if test "x$ECCODES_TEST_VERBOSE_OUTPUT" != "x"; then
set -x
fi
proj_dir=@PROJECT_SOURCE_DIR@
data_dir=@PROJECT_BINARY_DIR@/data

View File

@ -17,6 +17,12 @@ else
echo
echo "TEST: $0"
# If this environment variable is set, then become verbose
# so one can see why and how a test failed
if test "x$ECCODES_TEST_VERBOSE_OUTPUT" != "x"; then
set -x
fi
if [ -z "${data_dir}" ]
then
cd ../../

View File

@ -1,6 +1,12 @@
# examples/python include file for CMake
set -ea
# If this environment variable is set, then become verbose
# so one can see why and how a test failed
if test "x$ECCODES_TEST_VERBOSE_OUTPUT" != "x"; then
set -x
fi
proj_dir=@PROJECT_SOURCE_DIR@
data_dir=@PROJECT_BINARY_DIR@/data

View File

@ -8,6 +8,12 @@ else
echo
echo "TEST: $0"
# If this environment variable is set, then become verbose
# so one can see why and how a test failed
if test "x$ECCODES_TEST_VERBOSE_OUTPUT" != "x"; then
set -x
fi
cpath=$TOPBUILDDIR
ECCODES_DEFINITION_PATH=$cpath/definitions
export ECCODES_DEFINITION_PATH