287 <hlm:update basedir="${repo.dir}/new" /> |
287 <hlm:update basedir="${repo.dir}/new" /> |
288 </hlm:scm> |
288 </hlm:scm> |
289 </target> |
289 </target> |
290 |
290 |
291 <target name="test-update-basedir-tag" depends="test-checkin"> |
291 <target name="test-update-basedir-tag" depends="test-checkin"> |
|
292 <echo file="${repo.dir}/test1/not_in_repo.txt">Not in repo</echo> |
|
293 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
|
294 <hlm:add> |
|
295 <fileset dir="${repo.dir}/test1"> |
|
296 <include name="**" /> |
|
297 <exclude name="**/.${repo.type}/**" /> |
|
298 </fileset> |
|
299 </hlm:add> |
|
300 <hlm:checkin message="Adding not_in_repo.txt..."> |
|
301 <fileset dir="${repo.dir}/test1"> |
|
302 <include name="not_in_repo.txt" /> |
|
303 </fileset> |
|
304 </hlm:checkin> |
|
305 <hlm:tag baseDir="${repo.dir}/test1" name="tag_0.1" /> |
|
306 <hlm:tags baseDir="${repo.dir}/test1" /> |
|
307 </hlm:scm> |
292 <echo file="${repo.dir}/test1/not_in_repo2.txt">Not in repo2</echo> |
308 <echo file="${repo.dir}/test1/not_in_repo2.txt">Not in repo2</echo> |
293 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
309 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
294 <hlm:add> |
310 <hlm:add> |
295 <fileset dir="${repo.dir}/test1"> |
311 <fileset dir="${repo.dir}/test1"> |
296 <include name="**" /> |
312 <include name="**" /> |
297 <exclude name="**/.${repo.type}/**" /> |
313 <exclude name="**/.${repo.type}/**" /> |
298 </fileset> |
314 </fileset> |
299 </hlm:add> |
315 </hlm:add> |
300 </hlm:scm> |
|
301 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
|
302 <hlm:checkin message="Adding not_in_repo2.txt..."> |
316 <hlm:checkin message="Adding not_in_repo2.txt..."> |
303 <fileset dir="${repo.dir}/test1"> |
317 <fileset dir="${repo.dir}/test1"> |
304 <include name="not_in_repo2.txt" /> |
318 <include name="not_in_repo2.txt" /> |
305 </fileset> |
319 </fileset> |
306 </hlm:checkin> |
320 </hlm:checkin> |
307 </hlm:scm> |
321 <hlm:tag baseDir="${repo.dir}/test1" name="tag_0.2" /> |
|
322 <hlm:tags baseDir="${repo.dir}/test1" /> |
|
323 </hlm:scm> |
|
324 <au:assertLogContains text=" * tag_0.1" /> |
|
325 <au:assertLogContains text=" * tag_0.2" /> |
|
326 <!-- Updating to first tag, only not_in_repo.txt file should be present --> |
308 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
327 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
309 <hlm:update basedir="${repo.dir}/test1"> |
328 <hlm:update basedir="${repo.dir}/test1"> |
310 <hlm:tag name="0" /> |
329 <hlm:tag name="tag_0.1" /> |
311 </hlm:update> |
330 </hlm:update> |
312 </hlm:scm> |
331 </hlm:scm> |
|
332 <au:assertLogContains text="not_in_repo2.txt:patched" /> <!-- The file is removed so patched --> |
|
333 <au:assertFileExists file="${repo.dir}/test1/not_in_repo.txt" /> |
313 <au:assertFileDoesntExist file="${repo.dir}/test1/not_in_repo2.txt" /> |
334 <au:assertFileDoesntExist file="${repo.dir}/test1/not_in_repo2.txt" /> |
|
335 |
|
336 <!-- Updating to first tag, only not_in_repo.txt file should be present --> |
|
337 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
|
338 <hlm:update basedir="${repo.dir}/test1"> |
|
339 <hlm:tag name="tag_0.2" /> |
|
340 </hlm:update> |
|
341 </hlm:scm> |
|
342 <au:assertLogContains text="not_in_repo2.txt:patched" /> <!-- The file is added so patched --> |
|
343 <au:assertFileExists file="${repo.dir}/test1/not_in_repo.txt" /> |
|
344 <au:assertFileExists file="${repo.dir}/test1/not_in_repo2.txt" /> |
314 </target> |
345 </target> |
315 |
346 |
316 <target name="test-update-basedir-revision" depends="test-checkin"> |
347 <target name="test-update-basedir-revision" depends="test-checkin"> |
317 <echo file="${repo.dir}/test1/not_in_repo2.txt">Not in repo2</echo> |
348 <echo file="${repo.dir}/test1/not_in_repo2.txt">Not in repo2</echo> |
318 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |
349 <hlm:scm verbose="true" scmUrl="scm:${repo.type}:${repo.dir}/test1"> |