]>
Commit | Line | Data |
---|---|---|
729e4ab9 A |
1 | @echo off\r |
2 | REM ********************************************************************\r | |
3 | REM * COPYRIGHT:\r | |
4 | REM * Copyright (c) 2010, International Business Machines Corporation\r | |
5 | REM * and others. All Rights Reserved.\r | |
6 | REM ********************************************************************\r | |
7 | \r | |
8 | set ICU_ARCH=%1\r | |
9 | set ICU_DBRL=%2\r | |
10 | \r | |
11 | if "%1" == "" (\r | |
12 | echo Usage: %0 "x86 or x64" "Debug or Release"\r | |
13 | exit /b 1\r | |
14 | )\r | |
15 | \r | |
16 | if "%2" == "" (\r | |
17 | echo Usage: %0 %1 "Debug or Release"\r | |
18 | exit /b 1\r | |
19 | )\r | |
20 | \r | |
21 | set ICU_OPATH=%PATH%\r | |
22 | \r | |
23 | set ICU_ICUDIR=%~f0\..\..\..\r | |
24 | set ICU_BINDIR=%ICU_ICUDIR%\bin\r | |
25 | set PATH=%ICU_BINDIR%;%PATH%\r | |
26 | \r | |
27 | echo testing ICU in %ICU_ICUDIR% arch=%ICU_ARCH% type=%ICU_DBRL%\r | |
28 | pushd %ICU_ICUDIR%\r | |
29 | \r | |
30 | @rem factor these out\r | |
31 | set ICUINFO_CMD=%ICU_ICUDIR%\source\tools\icuinfo\%ICU_ARCH%\%ICU_DBRL%\icuinfo.exe\r | |
32 | set INTLTEST_CMD=%ICU_ICUDIR%\source\test\intltest\%ICU_ARCH%\%ICU_DBRL%\intltest.exe\r | |
33 | set IOTEST_CMD=%ICU_ICUDIR%\source\test\iotest\%ICU_ARCH%\%ICU_DBRL%\iotest.exe\r | |
34 | set CINTLTST_CMD=%ICU_ICUDIR%\source\test\cintltst\%ICU_ARCH%\%ICU_DBRL%\cintltst.exe\r | |
35 | set LETEST_CMD=%ICU_ICUDIR%\source\test\letest\%ICU_ARCH%\%ICU_DBRL%\letest.exe\r | |
36 | \r | |
37 | set ICUFAILED=\r | |
38 | set ICURUN=\r | |
39 | set ICUFAILCNT=0\r | |
40 | \r | |
41 | @echo on\r | |
42 | \r | |
43 | @set THT=icuinfo\r | |
44 | @echo ==== %THT% =========================================================================\r | |
45 | %ICUINFO_CMD% %ICUINFO_OPTS%\r | |
46 | \r | |
47 | @IF NOT ERRORLEVEL 1 GOTO OK_%THT%\r | |
48 | @set ICUFAILED=%ICUFAILED% %THT%\r | |
49 | @set ICUFAILCNT=1\r | |
50 | :OK_icuinfo\r | |
51 | @set ICURUN=%ICURUN% %THT%\r | |
52 | \r | |
53 | @set THT=intltest\r | |
54 | @echo ==== %THT% =========================================================================\r | |
55 | @cd %ICU_ICUDIR%\source\test\intltest\r | |
56 | %INTLTEST_CMD% %INTLTEST_OPTS%\r | |
57 | \r | |
58 | @IF NOT ERRORLEVEL 1 GOTO OK_%THT%\r | |
59 | @set ICUFAILED=%ICUFAILED% %THT%\r | |
60 | @set ICUFAILCNT=1\r | |
61 | :OK_intltest\r | |
62 | @set ICURUN=%ICURUN% %THT%\r | |
63 | \r | |
64 | @set THT=iotest\r | |
65 | @echo ==== %THT% =========================================================================\r | |
66 | @cd %ICU_ICUDIR%\source\test\iotest\r | |
67 | %IOTEST_CMD% %IOTEST_OPTS%\r | |
68 | \r | |
69 | @IF NOT ERRORLEVEL 1 GOTO OK_%THT%\r | |
70 | @set ICUFAILED=%ICUFAILED% %THT%\r | |
71 | @set ICUFAILCNT=1\r | |
72 | :OK_IOTEST\r | |
73 | @set ICURUN=%ICURUN% %THT%\r | |
74 | \r | |
75 | @set THT=cintltst\r | |
76 | @echo ==== %THT% =========================================================================\r | |
77 | @cd %ICU_ICUDIR%\source\test\cintltst\r | |
78 | %CINTLTST_CMD% %CINTLTST_OPTS%\r | |
79 | \r | |
80 | @IF NOT ERRORLEVEL 1 GOTO OK_%THT%\r | |
81 | @set ICUFAILED=%ICUFAILED% %THT%\r | |
82 | @set ICUFAILCNT=1\r | |
83 | :OK_cintltst\r | |
84 | @set ICURUN=%ICURUN% %THT%\r | |
85 | \r | |
86 | @set THT=letest\r | |
87 | @echo ==== %THT% =========================================================================\r | |
88 | @cd %ICU_ICUDIR%\source\test\letest\r | |
89 | %LETST_CMD% %LETEST_OPTS%\r | |
90 | \r | |
91 | @IF NOT ERRORLEVEL 1 GOTO OK_%THT%\r | |
92 | @set ICUFAILED=%ICUFAILED% %THT%\r | |
93 | @set ICUFAILCNT=1\r | |
94 | :OK_letest\r | |
95 | @set ICURUN=%ICURUN% %THT%\r | |
96 | \r | |
97 | @echo off\r | |
98 | \r | |
99 | REM clean up\r | |
100 | set PATH=%ICU_OPATH%\r | |
101 | REM unset ICU_OPATH\r | |
102 | popd\r | |
103 | \r | |
104 | @REM done\r | |
105 | \r | |
106 | echo -\r | |
107 | echo -\r | |
108 | echo -\r | |
109 | echo ============================================================\r | |
110 | echo Summary:\r | |
111 | echo -\r | |
112 | echo Tests Run : %ICURUN%\r | |
113 | \r | |
114 | if %ICUFAILCNT% == 0 (\r | |
115 | echo " - All Passed!"\r | |
116 | exit /b 0\r | |
117 | )\r | |
118 | echo Failing Tests: %ICUFAILED%\r | |
119 | echo -\r | |
120 | echo FAILED!\r | |
121 | \r | |
122 | exit /b 1 |