summaryrefslogtreecommitdiffstats
path: root/windows
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2009-06-16 18:06:14 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2009-06-16 18:06:14 (GMT)
commit8be813993f3bec3f17b4f8ab87a96abbb33851ba (patch)
tree945f27f5de527433775de6cdef8ab0807857fd5d /windows
parenteb668be9942b5678c7b10489dd8eae2c00efbf2f (diff)
downloadhdf5-8be813993f3bec3f17b4f8ab87a96abbb33851ba.zip
hdf5-8be813993f3bec3f17b4f8ab87a96abbb33851ba.tar.gz
hdf5-8be813993f3bec3f17b4f8ab87a96abbb33851ba.tar.bz2
[svn-r17057] Rev 17053 added new test to h5repack test script, which requires that the windows batch file be updated.
Tested: Windows XP32
Diffstat (limited to 'windows')
-rw-r--r--windows/tools/h5repack/h5repack.bat51
1 files changed, 47 insertions, 4 deletions
diff --git a/windows/tools/h5repack/h5repack.bat b/windows/tools/h5repack/h5repack.bat
index 009c64e..92f5300 100644
--- a/windows/tools/h5repack/h5repack.bat
+++ b/windows/tools/h5repack/h5repack.bat
@@ -64,13 +64,14 @@ set file13=h5repack_soffset.h5
rem A file with an older version of the layout message (copy of test/tlayouto.h5)
set file14=h5repack_layouto.h5
set file15=h5repack_named_dtypes.h5
+rem located in common testfiles folder
+set file16=tfamilyPERCENT05d.h5
set nerrors=0
set verbose=yes
-
goto main
@@ -85,7 +86,9 @@ rem
set test_msg=!test_msg! %%~nxa
) )
)
- set test_msg=!test_msg!
+ rem We need to replace PERCENT here with "%" for tests that use a percent
+ rem sign. --SJW 5/12/08
+ set test_msg=!test_msg:PERCENT=%%!
echo.%test_msg:~0,69% %1
exit /b
@@ -102,7 +105,9 @@ rem
set test_msg=!test_msg! %%~nxa
) )
)
- set test_msg=!test_msg!
+ rem We need to replace PERCENT here with "%" for tests that use a percent
+ rem sign. --SJW 5/12/08
+ set test_msg=!test_msg:PERCENT=%%!
echo.%test_msg:~0,69% %1
exit /b
@@ -118,7 +123,8 @@ rem was unavailable)
rem Call the h5diff tool
rem
:difftest
- %h5diff_bin% -q %*
+ set params=%*
+ %h5diff_bin% -q !params:PERCENT=%%!
if %errorlevel% neq 0 (
call :verify *FAILED* %*
set /a nerrors=!nerrors!+1
@@ -196,6 +202,40 @@ rem
exit /b
+rem same as TOOLTEST, but it uses the common testfiles at $srcdir/../testfiles/
+rem used to test the family driver, where these files reside
+rem
+:tooltest1
+
+ rem Run test.
+ set infile=%CD%\..\testfiles\%1
+ rem Linux uses a $path variable here, but it is unneccessary, and will
+ rem corrupt our Windows PATH if we use it. --SJW 8/28/07
+ rem set path=%CD%
+ rem set outfile=%path%\out.%1
+ set outfile=%CD%\out.%1
+
+ rem We define %params% here because Windows `shift` command doesn't affect
+ rem the %* variable. --SJW 8/28/07
+ if "%2"=="" (
+ set params=
+ ) else (
+ set params=%*
+ set params=!params:* =!
+ )
+ %h5repack_bin% %params% !infile:PERCENT=%%! !outfile:PERCENT=%%!
+
+ if %errorlevel% neq 0 (
+ call :testing *FAILED* %*
+ set /a nerrors=!nerrors!+1
+ ) else (
+ call :testing PASSED %*
+ call :difftest %infile% %outfile%
+ )
+ del /f !outfile:PERCENT=%%!
+
+ exit /b
+
rem This is a Windows-specific function that detects if the filter passed
rem should be enabled for this test script. It searches H5pubconf.h for the
@@ -611,6 +651,9 @@ rem
rem Check repacking file with committed datatypes in odd configurations
call :tooltest %file15%
+ rem tests family driver (file is located in common testfiles folder, uses TOOLTEST1
+ call :tooltest1 %file16%
+
if %nerrors% equ 0 (
echo.All %h5repack% tests passed.