Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

117 lines
3.3 KiB

  1. @REM =================================================================
  2. @REM ==
  3. @REM == regress.bat -- ISPU regression tests
  4. @REM ==
  5. @REM == called from ISPU/REGRESS.BAT
  6. @REM ==
  7. @REM == parameters if called from main regress:
  8. @REM == 1 = -!
  9. @REM == 2 = ispu base directory (eg: \nt\private\ispunt)
  10. @REM == 3 = parameters passed in to original regress.bat
  11. @REM == ...
  12. @REM ==
  13. @REM =================================================================
  14. @echo off
  15. @SETLOCAL ENABLEEXTENSIONS
  16. @set THISDIR=pkisign\tests
  17. @set BASEDIR=%_NTDRIVE%%_NTROOT%\private\ispunt
  18. @set LOGFILE=%BASEDIR%\regress.out
  19. @set __CalledFromMain=FALSE
  20. @set _CDB_=
  21. @set DEBUG_MASK=
  22. @set DEBUG_PRINT_MASK=
  23. @REM =====================================================
  24. :PrsCmdLine
  25. @REM =====================================================
  26. @if /i "%1" == "-!" @goto Param_!
  27. @if /i "%1" == "-?" @goto NeedHelp
  28. @if /i "%1" == "-d" @goto Param_d
  29. @if /i "%1" == "-v" @goto Param_v
  30. @if /i "%1" == "-l" @goto Param_l
  31. @if /i "%1" == "" @goto PrsCmdDone
  32. @shift
  33. @goto PrsCmdLine
  34. @REM =====================================================
  35. :NeedHelp
  36. @REM =====================================================
  37. @echo Usage: regress [switches]
  38. @echo -d enable all debug_print_masks
  39. @echo -v verbose (don't suppress echo)
  40. @echo -l check for memory leaks (default=no)
  41. @goto ExitRegress
  42. @REM =====================================================
  43. :Param_!
  44. @REM =====================================================
  45. @shift
  46. @if "%1" == "" @goto NeedHelp
  47. @set __CalledFromMain=TRUE
  48. @set BASEDIR=%1
  49. @set LOGFILE=%BASEDIR%\regress.out
  50. @shift
  51. @goto PrsCmdLine
  52. @REM =====================================================
  53. :Param_v
  54. @REM =====================================================
  55. @echo on
  56. @shift
  57. @goto PrsCmdLine
  58. @REM =====================================================
  59. :Param_d
  60. @REM =====================================================
  61. @set DEBUG_PRINT_MASK=0xFFFFFFFF
  62. @shift
  63. @goto PrsCmdLine
  64. @REM =====================================================
  65. :Param_l
  66. @REM =====================================================
  67. @set _CDB_=cdb -g -G
  68. @set DEBUG_MASK=0x20
  69. @shift
  70. @goto PrsCmdLine
  71. @REM =====================================================
  72. :PrsCmdDone
  73. @REM =====================================================
  74. @if NOT "%__CalledFromMain%" == "TRUE" @if exist %LOGFILE% del %LOGFILE%
  75. @cd %BASEDIR%\%THISDIR%
  76. @goto StartTests
  77. @REM =====================================================
  78. :StartTests
  79. @REM =====================================================
  80. REM ---- do tests here
  81. @goto ExitRegress
  82. @REM =====================================================
  83. :ExitRegress
  84. @REM =====================================================
  85. @cd %BASEDIR%
  86. @if "%__CalledFromMain%" == "TRUE" @goto EndGrep
  87. @call grepout.bat %LOGFILE%
  88. :EndGrep
  89. @ENDLOCAL
  90. goto :EOF