179
|
1 |
<?xml version="1.0" encoding="UTF-8"?>
|
|
2 |
<!--
|
|
3 |
============================================================================
|
|
4 |
Name : test_rebaseanddeconf_task.ant.xml
|
|
5 |
Part of : Helium
|
|
6 |
|
|
7 |
Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
|
|
8 |
All rights reserved.
|
|
9 |
This component and the accompanying materials are made available
|
|
10 |
under the terms of the License "Eclipse Public License v1.0"
|
|
11 |
which accompanies this distribution, and is available
|
|
12 |
at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
13 |
|
|
14 |
Initial Contributors:
|
|
15 |
Nokia Corporation - initial contribution.
|
|
16 |
|
|
17 |
Contributors:
|
|
18 |
|
|
19 |
Description:
|
|
20 |
|
|
21 |
============================================================================
|
|
22 |
-->
|
|
23 |
<project name="test_rebaseanddeconf_task" xmlns:au="org.apache.ant.antunit" xmlns:hlm="http://www.nokia.com/helium">
|
|
24 |
<description>
|
|
25 |
Rebaseline and Deconfigure testing targets for script rbt.pl
|
|
26 |
</description>
|
|
27 |
<property environment="env"/>
|
|
28 |
|
|
29 |
<property name="helium.dir" location="../../.." />
|
|
30 |
<import file="../../../helium.ant.xml"/>
|
|
31 |
|
|
32 |
|
|
33 |
<target name="test-rebaseanddeconf-no-arguments-case">
|
|
34 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
35 |
<hlm:rebaseanddeconf/>
|
|
36 |
</au:expectfailure>
|
|
37 |
</target>
|
|
38 |
|
|
39 |
<target name="test-rebaseanddeconf-task-database-set-case">
|
|
40 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - password">
|
|
41 |
<hlm:rebaseanddeconf database="to1tobet"/>
|
|
42 |
</au:expectfailure>
|
|
43 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
44 |
</target>
|
|
45 |
|
|
46 |
<target name="test-rebaseanddeconf-task-ccmproject-set-case">
|
|
47 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
48 |
<hlm:rebaseanddeconf ccmProject="helium-to1tobet#helium_4.49:project:vc1s60p1#1"/>
|
|
49 |
</au:expectfailure>
|
|
50 |
<au:assertLogContains text="Set ccmProject to helium-to1tobet#helium_4.49:project:vc1s60p1#1" />
|
|
51 |
</target>
|
|
52 |
|
|
53 |
<target name="test-rebaseanddeconf-task-password-set-case">
|
|
54 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database">
|
|
55 |
<hlm:rebaseanddeconf password="test"/>
|
|
56 |
</au:expectfailure>
|
|
57 |
<au:assertLogContains text="Set password to ******" />
|
|
58 |
</target>
|
|
59 |
|
|
60 |
<target name="test-rebaseanddeconf-task-release-set-case">
|
|
61 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
62 |
<hlm:rebaseanddeconf release="tony/test"/>
|
|
63 |
</au:expectfailure>
|
|
64 |
<au:assertLogContains text="Set release to tony/test" />
|
|
65 |
</target>
|
|
66 |
|
|
67 |
<target name="test-rebaseanddeconf-task-baseline-set-case">
|
|
68 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
69 |
<hlm:rebaseanddeconf baseline="helium-to1tobet#helium_4.49:project:vc1s60p1#1"/>
|
|
70 |
</au:expectfailure>
|
|
71 |
<au:assertLogContains text="Set baseline to helium-to1tobet#helium_4.49:project:vc1s60p1#1" />
|
|
72 |
</target>
|
|
73 |
|
|
74 |
<target name="test-rebaseanddeconf-task-version-set-case">
|
|
75 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
76 |
<hlm:rebaseanddeconf version="RnD_2007wk49"/>
|
|
77 |
</au:expectfailure>
|
|
78 |
<au:assertLogContains text="Set version to RnD_2007wk49" />
|
|
79 |
</target>
|
|
80 |
|
|
81 |
<target name="test-rebaseanddeconf-task-releasebaseline-set-case">
|
|
82 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
83 |
<hlm:rebaseanddeconf releaseBaseline="yes"/>
|
|
84 |
</au:expectfailure>
|
|
85 |
<au:assertLogContains text="Set releaseBaseline to true" />
|
|
86 |
</target>
|
|
87 |
|
|
88 |
<target name="test-rebaseanddeconf-task-leavefolders-writable-set-case">
|
|
89 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
90 |
<hlm:rebaseanddeconf leaveFoldersWritable="yes"/>
|
|
91 |
</au:expectfailure>
|
|
92 |
<au:assertLogContains text="Set leaveFoldersWritable to true" />
|
|
93 |
</target>
|
|
94 |
|
|
95 |
<target name="test-rebaseanddeconf-task-enabletask-rebadging-set-case">
|
|
96 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
97 |
<hlm:rebaseanddeconf enableTaskRebadging="yes"/>
|
|
98 |
</au:expectfailure>
|
|
99 |
<au:assertLogContains text="Set enableTaskRebadging to true" />
|
|
100 |
</target>
|
|
101 |
|
|
102 |
<target name="test-rebaseanddeconf-task-enabletask-rebadging-generic-release-set-case">
|
|
103 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
104 |
<hlm:rebaseanddeconf enableTaskRebadgingGenericRelease="yes"/>
|
|
105 |
</au:expectfailure>
|
|
106 |
<au:assertLogContains text="Set enableTaskRebadgingGenericRelease to true" />
|
|
107 |
</target>
|
|
108 |
|
|
109 |
<target name="test-rebaseanddeconf-task-rebadge-object-versions-set-case">
|
|
110 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
111 |
<hlm:rebaseanddeconf rebadgeObjectVersions="yes"/>
|
|
112 |
</au:expectfailure>
|
|
113 |
<au:assertLogContains text="Set rebadgeObjectVersions to true" />
|
|
114 |
</target>
|
|
115 |
|
|
116 |
<target name="test-rebaseanddeconf-task-newbaselinename-set-to-quiet-case">
|
|
117 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
118 |
<hlm:rebaseanddeconf newBaselineName="shoephone-RnD_2007wk49_01project:co1train#1"/>
|
|
119 |
</au:expectfailure>
|
|
120 |
<au:assertLogContains text="Set newBaselineName to shoephone-RnD_2007wk49_01project:co1train#1" />
|
|
121 |
</target>
|
|
122 |
|
|
123 |
<target name="test-rebaseanddeconf-task-use-branchrelease-methodology-set-case">
|
|
124 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
125 |
<hlm:rebaseanddeconf useBranchReleaseMethodology="yes"/>
|
|
126 |
</au:expectfailure>
|
|
127 |
<au:assertLogContains text="Set useBranchReleaseMethodology to true" />
|
|
128 |
</target>
|
|
129 |
|
|
130 |
<target name="test-rebaseanddeconf-task-create-baseline-for-rollingreleasetag-set-case">
|
|
131 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
132 |
<hlm:rebaseanddeconf createBaselineForRollingReleaseTag="yes"/>
|
|
133 |
</au:expectfailure>
|
|
134 |
<au:assertLogContains text="Set createBaselineForRollingReleaseTag to true" />
|
|
135 |
</target>
|
|
136 |
|
|
137 |
<target name="test-rebaseanddeconf-task-verbosity-set-to-quiet-case">
|
|
138 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
139 |
<hlm:rebaseanddeconf verbosity="0"/>
|
|
140 |
</au:expectfailure>
|
|
141 |
<au:assertLogContains text="Set verbosity to 0" />
|
|
142 |
</target>
|
|
143 |
|
|
144 |
<target name="test-rebaseanddeconf-task-verbosity-set-to-verbose-case">
|
|
145 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database password">
|
|
146 |
<hlm:rebaseanddeconf verbosity="1"/>
|
|
147 |
</au:expectfailure>
|
|
148 |
<au:assertLogContains text="Set verbosity to 1" />
|
|
149 |
</target>
|
|
150 |
|
|
151 |
<target name="test-rebaseanddeconf-task-database-and-ccmproject-set-case">
|
|
152 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - password">
|
|
153 |
<hlm:rebaseanddeconf database="to1tobet" ccmProject="helium-to1tobet#helium_4.49:project:vc1s60p1#1"/>
|
|
154 |
</au:expectfailure>
|
|
155 |
</target>
|
|
156 |
|
|
157 |
<target name="test-rebaseanddeconf-task-database-and-baseline-set-case">
|
|
158 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - password">
|
|
159 |
<hlm:rebaseanddeconf database="to1tobet" baseline="helium-to1tobet#helium_4.49:project:vc1s60p1#1"/>
|
|
160 |
</au:expectfailure>
|
|
161 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
162 |
<au:assertLogContains text="Set baseline to helium-to1tobet#helium_4.49:project:vc1s60p1#1" />
|
|
163 |
</target>
|
|
164 |
|
|
165 |
<target name="test-rebaseanddeconf-task-ccmproject-and-password-set-case">
|
|
166 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database">
|
|
167 |
<hlm:rebaseanddeconf ccmProject="helium-to1tobet#helium_4.49:project:vc1s60p1#1" password="test"/>
|
|
168 |
</au:expectfailure>
|
|
169 |
</target>
|
|
170 |
|
|
171 |
<target name="test-rebaseanddeconf-task-baseline-and-password-set-case">
|
|
172 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: mandatory attributes are not defined - database">
|
|
173 |
<hlm:rebaseanddeconf baseline="helium-to1tobet#helium_4.49:project:vc1s60p1#1" password="test"/>
|
|
174 |
</au:expectfailure>
|
|
175 |
<au:assertLogContains text="Set baseline to helium-to1tobet#helium_4.49:project:vc1s60p1#1" />
|
|
176 |
<au:assertLogContains text="Set password to ******" />
|
|
177 |
</target>
|
|
178 |
|
|
179 |
<target name="test-rebaseanddeconf-task-all-mandatory-arguments-with-ccmproject-given-but-password-wrong-case">
|
|
180 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Script execution failure.">
|
|
181 |
<hlm:rebaseanddeconf database="to1tobet" ccmProject="helium-to1tobet#helium_4.49:project:vc1s60p1#1" password="test"/>
|
|
182 |
</au:expectfailure>
|
|
183 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
184 |
<au:assertLogContains text="Set ccmProject to helium-to1tobet#helium_4.49:project:vc1s60p1#1" />
|
|
185 |
<au:assertLogContains text="Set password to ******" />
|
|
186 |
</target>
|
|
187 |
|
|
188 |
<target name="test-rebaseanddeconf-task-all-mandatory-arguments-with-baseline-given-but-password-wrong-case">
|
|
189 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Script execution failure.">
|
|
190 |
<hlm:rebaseanddeconf database="to1tobet" baseline="helium-to1tobet#helium_4.49:project:vc1s60p1#1" password="test"/>
|
|
191 |
</au:expectfailure>
|
|
192 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
193 |
<au:assertLogContains text="Set baseline to helium-to1tobet#helium_4.49:project:vc1s60p1#1" />
|
|
194 |
<au:assertLogContains text="Set password to ******" />
|
|
195 |
</target>
|
|
196 |
|
|
197 |
<target name="test-rebaseanddeconf-task-all-mandatory-arguments-and-optional-arguments-given-but-password-wrong-case">
|
|
198 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Script execution failure.">
|
|
199 |
<hlm:rebaseanddeconf database="to1tobet" ccmProject="symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" password="test" verbosity="1"/>
|
|
200 |
</au:expectfailure>
|
|
201 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
202 |
<au:assertLogContains text="Set ccmProject to symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" />
|
|
203 |
<au:assertLogContains text="Set password to ******"/>
|
|
204 |
<au:assertLogContains text="Set verbosity to 1" />
|
|
205 |
</target>
|
|
206 |
|
|
207 |
<target name="test-rebaseanddeconf-task-all-mandatory-arguments-and-optional-arguments-given-but-password-wrong-and-verbosity-wrong-case">
|
|
208 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Verbosity level is not recognised. Legal values are: 0 - quiet, 1 - verbose, 2 - Interactive or 3 - Walk-through Rehearsal">
|
|
209 |
<hlm:rebaseanddeconf database="to1tobet" ccmProject="symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" password="test" verbosity="9"/>
|
|
210 |
</au:expectfailure>
|
|
211 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
212 |
<au:assertLogContains text="Set ccmProject to symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" />
|
|
213 |
<au:assertLogContains text="Set password to ******"/>
|
|
214 |
<au:assertLogContains text="Set verbosity to 9" />
|
|
215 |
</target>
|
|
216 |
|
|
217 |
<target name="test-rebaseanddeconf-task-database-password-ccmproject-and-baseline-set-case">
|
|
218 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Option 'baseline' cannot be used with 'ccmProject' and 'newBaselineName'">
|
|
219 |
<hlm:rebaseanddeconf database="to1tobet" ccmProject="symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" password="test" verbosity="1"
|
|
220 |
baseline="symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1"/>
|
|
221 |
</au:expectfailure>
|
|
222 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
223 |
<au:assertLogContains text="Set ccmProject to symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" />
|
|
224 |
<au:assertLogContains text="Set password to ******"/>
|
|
225 |
<au:assertLogContains text="Set verbosity to 1" />
|
|
226 |
<au:assertLogContains text="Set baseline to symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" />
|
|
227 |
</target>
|
|
228 |
|
|
229 |
<target name="test-rebaseanddeconf-task-database-password-baseline-newbaselineName-set-case">
|
|
230 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Option 'baseline' cannot be used with 'ccmProject' and 'newBaselineName'">
|
|
231 |
<hlm:rebaseanddeconf database="to1tobet" password="test" verbosity="1"
|
|
232 |
baseline="symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" newBaselineName="shoephone-RnD_2007wk49_01project:co1train#1"/>
|
|
233 |
</au:expectfailure>
|
|
234 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
235 |
<au:assertLogContains text="Set baseline to symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" />
|
|
236 |
<au:assertLogContains text="Set password to ******"/>
|
|
237 |
<au:assertLogContains text="Set verbosity to 1" />
|
|
238 |
<au:assertLogContains text="Set newBaselineName to shoephone-RnD_2007wk49_01project:co1train#1" />
|
|
239 |
</target>
|
|
240 |
|
|
241 |
<target name="test-rebaseanddeconf-task-database-password-baseline-enabletaskrebadging-and-enabletaskrebadginggenericrelease-set-case">
|
|
242 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Use Option either 'enableTaskRebadging' or 'enableTaskRebadgingGenericRelease'">
|
|
243 |
<hlm:rebaseanddeconf database="to1tobet" password="test" verbosity="1"
|
|
244 |
baseline="symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" enableTaskRebadging="yes" enableTaskRebadgingGenericRelease="yes"/>
|
|
245 |
</au:expectfailure>
|
|
246 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
247 |
<au:assertLogContains text="Set baseline to symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" />
|
|
248 |
<au:assertLogContains text="Set password to ******" />
|
|
249 |
<au:assertLogContains text="Set verbosity to 1" />
|
|
250 |
<au:assertLogContains text="Set enableTaskRebadging to true" />
|
|
251 |
<au:assertLogContains text="Set enableTaskRebadgingGenericRelease to true" />
|
|
252 |
</target>
|
|
253 |
|
|
254 |
<target name="test-rebaseanddeconf-task-database-password-baseline-replacesubprojects-and-dontreplacesubprojects-set-case">
|
|
255 |
<au:expectfailure expectedMessage="[hlm:rebaseanddeconf] Error: Use option either 'deconfigure' or 'skipDeconfigure'">
|
|
256 |
<hlm:rebaseanddeconf database="to1tobet" password="test" verbosity="1"
|
|
257 |
baseline="symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" deconfigure="yes" skipDeconfigure="yes"/>
|
|
258 |
</au:expectfailure>
|
|
259 |
<au:assertLogContains text="Set database to to1tobet" />
|
|
260 |
<au:assertLogContains text="Set baseline to symbiantools-to1tobet#symbiantools_08_w34:project:ccm51#1" />
|
|
261 |
<au:assertLogContains text="Set password to ******"/>
|
|
262 |
<au:assertLogContains text="Set verbosity to 1" />
|
|
263 |
<au:assertLogContains text="Set deconfigure to true" />
|
|
264 |
<au:assertLogContains text="Set skipDeconfigure to true" />
|
|
265 |
</target>
|
|
266 |
</project>
|