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