REM\r
REM Run some tests on the Windows version of wimlib-imagex.\r
REM\r
-REM This must be run on Windows Vista or later in a clean directory, with\r
-REM Administrator privileges. wimlib-imagex and win32-tree-cmp must be\r
-REM executable using the paths set below.\r
+REM This must be run in a clean directory, with Administrator privileges.\r
+REM wimlib-imagex, win32-tree-cmp, and set_reparse_point must be executable\r
+REM using the paths set below.\r
\r
setlocal EnableDelayedExpansion\r
set WIMLIB_IMAGEX=wimlib-imagex\r
fsutil objectid set f67394c12b17608e1d050d181ba8ffd2 7df80cbdf620f4c82c79b9e6799147b6 97621aff72915ade05abb96b15dea1a3 e0bda4caa9e33cfd461c92c16be9713d subdir\r
call :do_test\r
\r
+call :msg "sparse files"\r
+fsutil file createnew sparse 1000000 > nul\r
+fsutil sparse setflag sparse\r
+fsutil sparse setrange sparse 0 1000000\r
+\r
+fsutil file createnew mostly_sparse 1000000 > nul\r
+fsutil sparse setflag mostly_sparse\r
+fsutil sparse setrange mostly_sparse 0 1000000\r
+echo hello >> mostly_sparse\r
+type sparse >> mostly_sparse\r
+fsutil sparse setrange mostly_sparse 1000100 2000000\r
+call :do_test\r
+\r
+call :msg "sparse and compressed files"\r
+fsutil file createnew sparse 1000000 > nul\r
+fsutil sparse setflag sparse\r
+fsutil sparse setrange sparse 0 1000000\r
+compact /c sparse > nul\r
+\r
+fsutil file createnew mostly_sparse 1000000 > nul\r
+fsutil sparse setflag mostly_sparse\r
+fsutil sparse setrange mostly_sparse 0 1000000\r
+echo hello >> mostly_sparse\r
+type sparse >> mostly_sparse\r
+fsutil sparse setrange mostly_sparse 1000100 2000000\r
+compact /c mostly_sparse > nul\r
+\r
+type nul > compressed_first\r
+compact /c compressed_first > nul\r
+type sparse >> compressed_first\r
+fsutil sparse setflag compressed_first\r
+fsutil sparse setrange compressed_first 0 500000\r
+call :do_test\r
+\r
:rpfix_tests\r
\r
echo Testing rpfix junction\r