summaryrefslogtreecommitdiffstats
path: root/windows/hdf5check.BAT
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2009-10-22 21:23:59 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2009-10-22 21:23:59 (GMT)
commit5d27012937307b5027ae28d17715b12ea959cc29 (patch)
tree479538b56d79dae19dccdb295c85822872482d67 /windows/hdf5check.BAT
parent3916f4ef4d59da0d8939ec06dcd6dc5079c2cc70 (diff)
downloadhdf5-5d27012937307b5027ae28d17715b12ea959cc29.zip
hdf5-5d27012937307b5027ae28d17715b12ea959cc29.tar.gz
hdf5-5d27012937307b5027ae28d17715b12ea959cc29.tar.bz2
[svn-r17726] Updated the errorlevel checking for better error handling in the windows batch files.
Diffstat (limited to 'windows/hdf5check.BAT')
-rwxr-xr-xwindows/hdf5check.BAT21
1 files changed, 15 insertions, 6 deletions
diff --git a/windows/hdf5check.BAT b/windows/hdf5check.BAT
index f3caea2..ffa53f0 100755
--- a/windows/hdf5check.BAT
+++ b/windows/hdf5check.BAT
@@ -75,14 +75,19 @@ rem %2 - "dll" or nothing
:run_tests
for %%a in (%hdf5_test_tests%) do (
echo.
- echo.************************************
+ echo.**==**==**==**==**==**==**==**==**==**
echo. Testing %%a ^(%1 %2^)
- echo.************************************
+ echo.**==**==**==**==**==**==**==**==**==**
rem Only add our parameters for batch scripts.
call !hdf5_test_%%a_test:.bat= %1 %2!
rem Exit early if test fails.
- if !errorlevel! neq 0 exit /b
+ if errorlevel 1 (
+ set /a nerrors=!nerrors!+1
+ echo. Testing %%a ^(%1 %2^) FAILED
+ echo.**==**==**==**==**==**==**==**==**==**
+ exit /b 1
+ )
)
rem If we get here, that means all of our tests passed.
@@ -118,18 +123,22 @@ rem on it for sending parameters. --SJW 9/6/07
rem We use "nodll" here because we cannot simply leave it blank. Filter
rem it out below. --SJW 9/10/07
for %%b in (nodll dll) do (
+ echo.======================================
for %%a in (debug release) do (
set hdf5_config=%%a %%b
call :run_tests !hdf5_config:nodll=!
- if !errorlevel! neq 0 (
+ if errorlevel 1 (
set /a nerrors=!nerrors!+1
)
)
+ echo.======================================
)
- if %nerrors% equ 0 (
+ if "%nerrors%"=="0" (
echo.HDF5 Tests passed for all configurations!
- )
+ ) else (
+ echo.** FAILED HDF5 Tests!
+ )
popd
endlocal & exit /b %nerrors%